From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dan Nicolaescu Newsgroups: gmane.emacs.devel Subject: Re: emacs 24 randomly hanging Date: Tue, 21 Feb 2012 10:41:35 -0500 Message-ID: References: <878vjzz920.fsf@earth.home> <87sji4mpwn.fsf@this.that> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1329838910 26710 80.91.229.3 (21 Feb 2012 15:41:50 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 21 Feb 2012 15:41:50 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Feb 21 16:41:49 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Rzrqe-0004ed-7S for ged-emacs-devel@m.gmane.org; Tue, 21 Feb 2012 16:41:48 +0100 Original-Received: from localhost ([::1]:49111 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Rzrqc-0000UM-CL for ged-emacs-devel@m.gmane.org; Tue, 21 Feb 2012 10:41:46 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:40555) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RzrqX-0000Tw-2q for emacs-devel@gnu.org; Tue, 21 Feb 2012 10:41:45 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RzrqR-0001yr-Qz for emacs-devel@gnu.org; Tue, 21 Feb 2012 10:41:41 -0500 Original-Received: from fencepost.gnu.org ([140.186.70.10]:46870) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RzrqR-0001yn-GC for emacs-devel@gnu.org; Tue, 21 Feb 2012 10:41:35 -0500 Original-Received: from dann by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1RzrqR-0001eD-CG for emacs-devel@gnu.org; Tue, 21 Feb 2012 10:41:35 -0500 In-Reply-To: <87sji4mpwn.fsf@this.that> (Adam's message of "Tue, 21 Feb 2012 11:43:48 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.10 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:148697 Archived-At: Adam writes: > Adam writes: > >> I am using GNU Emacs 24.0.93.1 (x86_64-unknown-linux-gnu, GTK+ Version >> 2.20.1) of 2012-02-15, built from sources. >> >> I am constantly experiencing my emacs hanging. That is, C-g does not >> work, and the screen is not updated. It happens about twice a day or >> so, which is very annoying, as I only have one emacs instance up >> and running in which I am doing all my work. >> >> I am pretty sure emacs hanging has been discussed to death, and I am >> pretty sure I just screwed my emacs configuration up somewhere. What's >> worring me is that C-g does not work, though. In fact, nothing works. >> I have to send a SIGKILL to my emacs process to get rid of it. >> >> Here's a backtrace: > > [...] > >> (I am running emacs in daemon mode with about three or five open X11 >> clients. Although the backtrace references Fx_create_frame, I *did* not >> create a frame. I am using a tight intergration between my window >> manager and emacs though, and my window manager spawns about two >> `emacsclient -e' per second). >> >> Is this problem known? Could this be fixed in emacs 24? > > I am able to reproduce my problem with emacs -q. > > #+BEGIN_SRC sh > #!/bin/bash > > killall -9 emacsclient > > emacs -q --daemon || exit 1 > > emacsclient -e "(progn (require 'cl) > (defun walk-frames () > (loop for frame being the frames)) > (add-hook 'window-configuration-change-hook 'walk-frames))" > > for I in {1..100} > do > echo $I > emacsclient -e "(walk-frames)" >/dev/null & > emacsclient -c -e "(delete-frame)" >/dev/null & > done > > wait > > emacsclient -e "(kill-emacs 0)" > #+END_SRC I can reproduce this. It looks like there's an infinite loop in frame.c:next_frame. Maybe the frame list is not completely initialized when this code is run, there's a comment about looping forever in the function. Unfortunately I don't have time to dig more.