--- Begin Message ---
Subject: |
23.0.60; emacsclient -t not working within "less" |
Date: |
Mon, 16 Jun 2008 11:32:44 +0100 |
1) start emacs with "emacs -q -f server-start &"
2) export VISUAL="emacsclient -t"
2) less .bashrc
3) within less type "v" to edit file with $VISUAL
the result is that less writes a line
"!emacsclient -t +18 .bashrc" on the terminal, but other than that the
terminal is still showing the output of less. emacsclient
is not taking over the terminal, and no editing is possible.
Using "ps auxw" in another terminal, emacsclient appears in the
process list, though. The only thing I can do in the "less terminal"
is to type "C-c" to resume viewing the .bashrc file.
The problem seems to be specific to "emacsclient -t", since both
export VISUAL="emacsclient -c"
and
export VISUAL="emacs -nw"
work as expected.
The same problem occurs in both xterm and konsole.
In GNU Emacs 23.0.60.1 (x86_64-unknown-linux-gnu, X toolkit, Xaw3d scroll bars)
of 2008-06-11 on lnx0015f2465ec6
Windowing system distributor `The X.Org Foundation', version 11.0.10300000
configured using `configure '--prefix=/home/aamann/local/emacs-cvs'
'LDFLAGS=-L/home/aamann/local/lib64' 'CPPFLAGS=-I/home/aamann/local/include''
Important settings:
value of $LC_ALL: nil
value of $LC_COLLATE: nil
value of $LC_CTYPE: nil
value of $LC_MESSAGES: nil
value of $LC_MONETARY: nil
value of $LC_NUMERIC: nil
value of $LC_TIME: nil
value of $LANG: en_IE.utf8
value of $XMODIFIERS: @im=none
locale-coding-system: utf-8-unix
default-enable-multibyte-characters: t
Major mode: Lisp Interaction
Minor modes in effect:
tooltip-mode: t
tool-bar-mode: t
mouse-wheel-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
global-auto-composition-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
line-number-mode: t
transient-mark-mode: t
Recent input:
ESC [ > 0 ; 1 1 5 ; 0 c C-x C-c ESC [ > 0 ; 1 1 5 ;
0 c ESC [ > 0 ; 1 1 5 ; 0 c M-x b u <tab> <backspace>
<backspace> <backspace> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> <help-echo> <help-echo> <menu-bar>
<help-menu> <send-emacs-bug-report>
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
When done with this frame, type C-x 5 0
(No files need saving)
When done with this frame, type C-x 5 0 [2 times]
Making completion list...
call-interactively: Text is read-only
Quit
--- End Message ---
--- Begin Message ---
Subject: |
Re: 23.0.60; emacsclient -t not working within "less" |
Date: |
Fri, 19 Sep 2008 11:51:09 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) |
Dan Nicolaescu <dann@ics.uci.edu> writes:
> You can edebug `server-process-filter'. Doing that shows quickly the
> problem: emacsclient passes the tty as: -tty /dev/tty.
> /dev/tty means one thing for emacsclient and another one for emacs...
>
> emacsclient.c computes the tty like this:
>
> tty_name = ttyname (fileno (stdin));
>
> changing it to:
>
> tty_name = ttyname (fileno (stdout));
>
> gets the right terminal and this problem seems to be fixed.
That seems to work fine for me too. I checked in the fix. Thanks.
--- End Message ---