Subject: bug#11674: 24.1; desktop doesn't handle unclean restart under daemon mode

From: Ken Raeburn <[email-masked]>
Date: Mon, 11 Jun 2012 14:25:02 -0400

The default configuration of desktop (aside from actually enabling it,
via customize) can prompt as to whether a desktop configuration that
"appears to be in use" by another process should be used.

In daemon mode (e.g., started by emacsclient -c -a ""), the prompt is
displayed to stdout on the tty invoking emacsclient, if there is one.
(Maybe because emacs is started on that tty initially?)

If emacsclient is launched by a button in the gnome panel, so there is
no tty available, a stream of "Back to top level" messages seems to get
written to a log file (.xsession-errors), and I doesn't see anything
happen; no window comes up.

Yes, I can just adjust my preferences, and I probably will, but the
default behavior when both of these handy modes are used together
shouldn't be to loop if the desktop file seems to be in use.

In GNU Emacs 24.1.1 (x86_64-unknown-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2012-06-11 on just-testing.permabit.com
Windowing system distributor `The X.Org Foundation', version 11.0.10707000
Configured using:
 `configure
 '--prefix=/permabit/user/raeburn/I64/install/emacs-24.1.squeeze'
 '--with-x-toolkit=lucid''

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: C
  value of $XMODIFIERS: nil
  locale-coding-system: nil
  default enable-multibyte-characters: t

Major mode: CPerl

Minor modes in effect:
  rcirc-track-minor-mode: t
  whitespace-mode: t
  desktop-save-mode: t
  jabber-activity-mode: t
  display-time-mode: t
  which-function-mode: t
  icomplete-mode: t
  shell-dirtrack-mode: t
  tooltip-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Recent input:
<return> <help-echo> <help-echo> <down> <up> <return> 
<backspace> C-x u C-x u <help-echo> <help-echo> <help-echo> 
<help-echo> <help-echo> <help-echo> <help-echo> M-x 
e m a c s - <M-backspace> r e p o r t <tab> <return> 
C-g M-x e <backspace> r e p o <tab> r t - q <tab> <return> 
d e s k t o p , d a e m o n <return> <help-echo> <down> 
<down> <down> <down> <down> <down> <down> <down> <down> 
<down> <down> <down> <down> <down> <down> <down> <down> 
<down> <down> <down> <down> <down> <down> <down> <down> 
<down> <right> <right> <right> <right> <right> <right> 
<down> <down> <down> <down> <down> <down> <down> <down> 
<down> <down> <down> <down> <down> <down> <down> <down> 
<down> <down> <down> <down> <down> <down> <down> <down> 
<down> <down> <down> <down> <down> <down> <down> <down> 
<down> <down> <down> <down> <down> <return> <help-echo> 
C-l C-x C-b C-x 0 C-v C-v M-v M-v M-v M-< C-x k <return> 
C-f C-f C-h f C-g C-h c <return> C-x k <return> M-x 
r e p o r t - e m <tab> <return>

Recent messages:
Undo! [2 times]
Message in [email-masked]
Message in [email-masked]
Quit
Making completion list...
Contacting host: debbugs.gnu.org:80
Reporting new bug!
scroll-down-command: Beginning of buffer
Mark set
Quit
RET (translated from <return>) runs the command widget-button-press

Load-path shadows:
None found.

Features:
(shadow sort mail-extr gnus-msg network-stream url-cache url-http url-gw
url-auth url url-proxy url-privacy url-expand url-methods url-history
url-cookie url-util url-parse url-vars emacsbug sendmail goto-addr
thingatpt jabber-keepalive jabber-bookmarks jabber-private sasl-digest
hmac-md5 hex-util help-mode view mule-util server autorevert make-mode
sh-script executable vc-git c-eldoc eldoc rcirc whitespace desktop
cus-start cus-load jabber jabber-awesome jabber-osd jabber-wmii
jabber-xmessage jabber-festival jabber-sawfish jabber-ratpoison
jabber-screen jabber-socks5 jabber-ft-server jabber-si-server
jabber-ft-client jabber-ft-common jabber-si-client jabber-si-common
jabber-feature-neg jabber-truncate jabber-time jabber-autoaway
jabber-vcard-avatars jabber-chatstates jabber-events jabber-vcard
jabber-avatar jabber-activity jabber-watch jabber-modeline easy-mmode
jabber-ahc-presence jabber-ahc jabber-version jabber-ourversion
jabber-muc-nick-completion hippie-exp jabber-browse jabber-search
jabber-register jabber-roster edmacro kmacro jabber-presence jabber-muc
jabber-newdisco jabber-widget jabber-disco jabber-chat ewoc
jabber-history jabber-chatbuffer jabber-alert jabber-iq jabber-keymap
jabber-core jabber-sasl sasl sasl-anonymous sasl-login sasl-plain fsm
jabber-logon jabber-conn srv dns starttls jabber-xml jabber-menu
jabber-autoloads jabber-util cl idutils compile cperl-mode p4 timeclock
time cc-mode cc-fonts cc-guess cc-menus cc-cmds cc-styles cc-align
cc-engine cc-vars cc-defs warnings which-func imenu icomplete kr-stuff
ses unsafep nnimap parse-time tls utf7 netrc browse-url edit-server
gnus-demon nntp gnus-art mm-uu mml2015 epg-config mm-view mml-smime
smime dig mailcap gnus-sum nnoo gnus-group gnus-undo nnmail mail-source
gnus-start gnus-spec gnus-int gnus-range message rfc822 mml easymenu
mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045
ietf-drums mailabbrev gmm-utils mailheader gnus-win gnus gnus-ems
nnheader mail-utils wid-edit iso-transl notifications dbus xml tramp
tramp-compat auth-source eieio byte-opt bytecomp byte-compile cconv
macroexp assoc gnus-util time-date mm-util mail-prsvr password-cache
format-spec tramp-loaddefs ssh shell pcomplete comint regexp-opt
ansi-color ring uniquify advice help-fns advice-preload 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 font-render-setting x-toolkit x multi-tty
emacs)