From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Harald Hanche-Olsen Newsgroups: gmane.emacs.devel,gmane.emacs.pretest.bugs Subject: 23.0.60; Emacs should survive a lost X connection Date: Tue, 05 Feb 2008 15:58:47 +0100 (CET) Message-ID: <20080205.155847.56398348.hanche@math.ntnu.no> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1202234815 21331 80.91.229.12 (5 Feb 2008 18:06:55 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 5 Feb 2008 18:06:55 +0000 (UTC) To: emacs-pretest-bug@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Feb 05 19:07:16 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JMSBq-0002Ug-3T for ged-emacs-devel@m.gmane.org; Tue, 05 Feb 2008 19:06:38 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JMSBN-0000L5-Qs for ged-emacs-devel@m.gmane.org; Tue, 05 Feb 2008 13:06:09 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JMPGE-0004Ql-Mv for emacs-devel@gnu.org; Tue, 05 Feb 2008 09:58:58 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JMPGC-0004QM-Ek for emacs-devel@gnu.org; Tue, 05 Feb 2008 09:58:57 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JMPGC-0004QG-40 for emacs-devel@gnu.org; Tue, 05 Feb 2008 09:58:56 -0500 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JMPGB-000872-PN for emacs-devel@gnu.org; Tue, 05 Feb 2008 09:58:55 -0500 Original-Received: from mail.gnu.org ([199.232.76.166] helo=mx10.gnu.org) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1JMPGB-0002c7-BB for emacs-pretest-bug@gnu.org; Tue, 05 Feb 2008 09:58:55 -0500 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1JMPG7-000862-Pg for emacs-pretest-bug@gnu.org; Tue, 05 Feb 2008 09:58:54 -0500 Original-Received: from fiinbeck.math.ntnu.no ([129.241.15.140]) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1JMPG7-00085A-9g for emacs-pretest-bug@gnu.org; Tue, 05 Feb 2008 09:58:51 -0500 Original-Received: (qmail 30191 invoked from network); 5 Feb 2008 14:58:48 -0000 Original-Received: from localhost (127.0.0.1) by localhost with SMTP; 5 Feb 2008 14:58:48 -0000 X-URL: http://www.math.ntnu.no/~hanche/ X-Mailer: Mew version 5.2.52 on Emacs 23.0.60 / Mule 6.0 (HANACHIRUSATO) X-detected-kernel: by monty-python.gnu.org: FreeBSD 6.x (1) X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-Mailman-Approved-At: Tue, 05 Feb 2008 13:06:05 -0500 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:88289 gmane.emacs.pretest.bugs:20887 Archived-At: What I did: a deliberate test, not an accident - (and my apologies in the likely case that this is well known): I started emacs -nw, then ran M-x make-frame-on-display RET :0 RET. After the new frame popped up on display :0 (I did all this from an xterm not on that display), I logged out of display :0. Emacs aborted as a result. Here is the top of the backtrace. ; gdb /local/bin/emacs core Core was generated by `emacs'. Program terminated with signal 6, Aborted. (gdb) back #0 0x88c5eecb in kill () from /lib/libc.so.6 #1 0x080f860e in fatal_error_signal (sig=-1077966240) at emacs.c:398 #2 0x88a44f5d in sigaction () from /lib/libpthread.so.2 #3 0xbfbfff94 in ?? () #4 0x00000006 in ?? () #5 0xbfbf8e30 in ?? () #6 0xbfbf8b70 in ?? () #7 0x00000000 in ?? () #8 0x88a44a24 in sigaction () from /lib/libpthread.so.2 #9 0x0815a954 in internal_condition_case_2 ( bfun=0x815d5e0 , nargs=2, args=0xbfbf8f68, handlers=137623601, hfun=0x805cfe4 ) at eval.c:1568 #10 0x0805fd91 in Fdelete_frame (frame=137838641, force=137623601) at frame.c:1412 #11 0x080d5266 in x_connection_closed (dpy=0x860f335, error_message=0xbfbf9080 "Connection lost to X server `:0.0'") at xterm.c:8054 I am pretty sure this at the top of internal_condition_case_2 (eval.c:1568) is responsible: eval.c:1568 is where it dies deliberately: /* Since Fsignal will close off all calls to x_catch_errors, we will get the wrong results if some are not closed now. */ #if HAVE_X_WINDOWS if (x_catching_errors ()) abort (); #endif I am guessing that the code was not written for a lost X connection to be survivable, but perhaps I am wrong. But if I guessed right, consider this a feature request rather than a bug report: For multitty to be really useful, I think surviving a lost X connection can be important. Dropped connections can easily happen when accessing the office computer from a laptop, for example. In GNU Emacs 23.0.60.2 (i386-unknown-freebsd6.2, GTK+ Version 2.12.7) of 2008-02-03 on fiinbeck.math.ntnu.no Windowing system distributor `The X.Org Foundation', version 11.0.10400000 configured using `configure '--prefix' '/local'' 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: nil value of $XMODIFIERS: nil locale-coding-system: nil default-enable-multibyte-characters: t (Various other stuff elided, as it did not come from the dead emacs.) - Harald