Subject: 24.2; follow-mode breaks emacs' server instance

From: Miguel Guedes <[email-masked]>
Date: Tue, 02 Apr 2013 14:11:41 +0100

Description
-------------

Emacs's server instance breaks if follow-mode is enabled. Once
follow-mode is enabled attempting to invoke,

        $ emacsclient -n foo.c -a zile

results in neither emacs' currently active server receiving the request
to visit file `foo.c' nor zile being opened.

 Recipe
-------------

1) Start emacs with no site file

        $ emacs -Q

2) Inside emacs:
2.1) Start a server instance

        M-x server-start

2.2) Switch to follow-mode

        M-x follow-mode

3) Visit a file from the shell

        $ emacsclient -n foo.c -a zile

 Result
-------------

After step 3 is executed nothing happens and emacsclient simply hangs.
Only solution is to restart the server but as soon follow-mode is 
re-enabled emacsclient hangs again.

----------------------------------------------------------------------

In GNU Emacs 24.2.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.13)
 of 2012-11-06 on lakoocha, modified by Debian
Windowing system distributor `The X.Org Foundation', version
11.0.11300000
Configured using:
 `configure '--build' 'x86_64-linux-gnu' '--build' 'x86_64-linux-gnu'
 '--prefix=/usr' '--sharedstatedir=/var/lib' '--libexecdir=/usr/lib'
 '--localstatedir=/var/lib' '--infodir=/usr/share/info'
 '--mandir=/usr/share/man' '--with-pop=yes'

'--enable-locallisppath=/etc/emacs24:/etc/emacs:/usr/local/share/emacs/24.2/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/24.2/site-lisp:/usr/share/emacs/site-lisp'
 '--with-crt-dir=/usr/lib/x86_64-linux-gnu' '--with-x=yes'
 '--with-x-toolkit=gtk' '--with-toolkit-scroll-bars'
 'build_alias=x86_64-linux-gnu' 'CFLAGS=-g -O2 -fstack-protector
 --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall'
 'LDFLAGS=-Wl,-Bsymbolic-functions -Wl,-z,relro'
 'CPPFLAGS=-D_FORTIFY_SOURCE=2''

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_GB.UTF-8
  value of $XMODIFIERS: nil
  locale-coding-system: utf-8-unix
  default enable-multibyte-characters: t

Major mode: Emacs-Lisp

Minor modes in effect:
  shell-dirtrack-mode: t
  tooltip-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
C-x C-f / u s r / s h a r e / e m a c s / c o m m o 
n <tab> c o n f - p r g r o <backspace> <backspace> 
o g r <backspace> <backspace> <backspace> <backspace> 
o g r <return> C-x C-f p r o g r <backspace> c o <M-backspace> 
C-g C-g M-x t r a m p <tab> <return> M-x t r a m p 
<tab> <tab> C-g M-: M-( t r a <tab> m p <tab> <tab> 
s C-g C-g C-x C-f c o n f - r <backspace> p g r o <tab> 
<backspace> <backspace> <backspace> r o g r <tab> <return> 
C-n C-n C-n C-n C-n C-n C-n C-n C-n C-v C-n C-n C-n 
C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n 
C-n C-SPC M-} M-; C-n C-n C-SPC M-} M-; C-x C-s C-p 
C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p 
C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-n 
C-l C-n C-p C-n C-n C-n C-n C-n C-n C-SPC C-g C-a C-p 
C-SPC C-n C-n M-; C-x C-s C-p C-p C-p C-p C-p C-p C-a 
C-n C-n C-n C-n C-n <help-echo> <help-echo> <help-echo> 
<help-echo> <help-echo> <down-mouse-1> <mouse-1> <help-echo> 
<down-mouse-1> <mouse-1> M-x a p r o p o s SPC <backspace> 
<return> b u g s <backspace> SPC e m a c s <return> 
M-x r e p o r t - e m a c s - b u g <return>

Recent messages:
Making completion list... [2 times]
Quit [2 times]
Mark set [2 times]
Saving file /usr/share/emacs/common-lisp/conf-programming.el...
Wrote /usr/share/emacs/common-lisp/conf-programming.el
Mark set
Quit
Mark set
Saving file /usr/share/emacs/common-lisp/conf-programming.el...
Wrote /usr/share/emacs/common-lisp/conf-programming.el

Load-path shadows:
/usr/share/emacs/24.2/site-lisp/cmake-data/cmake-mode
hides /usr/share/emacs/site-lisp/cmake-mode
/usr/share/emacs/24.2/site-lisp/dictionaries-common/ispell
hides /usr/share/emacs/24.2/lisp/textmodes/ispell
/usr/share/emacs/24.2/site-lisp/dictionaries-common/flyspell
hides /usr/share/emacs/24.2/lisp/textmodes/flyspell

Features:
(shadow sort mail-extr emacsbug message rfc822 mml mml-sec mm-decode
mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader
sendmail rfc2047 rfc2045 ietf-drums mail-utils apropos newcomment
help-mode easymenu view loadhist auth-source eieio byte-opt bytecomp
byte-compile cconv macroexp assoc gnus-util mm-util mail-prsvr
password-cache shell pcomplete comint ansi-color ring format-spec advice
help-fns advice-preload tramp-loaddefs regexp-opt vc-git time-date
tooltip ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd tool-bar
dnd fontset image fringe lisp-mode register page menu-bar rfn-eshadow
timer select scroll-bar mouse jit-lock font-lock syntax facemenu
font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan
thai tai-viet lao korean japanese hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces
cus-face files text-properties overlay sha1 md5 base64 format env
code-pages mule custom widget hashtable-print-readable backquote
make-network-process dbusbind dynamic-setting system-font-setting
font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs)