delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2012/05/25/10:35:48

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Fri, 25 May 2012 16:35:03 +0200
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: "emacs -nw" hangs in a terminal
Message-ID: <20120525143503.GK4225@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <20120522134119 DOT GB9200 AT calimero DOT vinschen DOT de> <20120522134932 DOT GC9200 AT calimero DOT vinschen DOT de> <4FBCD166 DOT 8080101 AT cornell DOT edu> <20120523141538 DOT GI9200 AT calimero DOT vinschen DOT de> <4FBD08B0 DOT 50209 AT cornell DOT edu> <20120523160235 DOT GK9200 AT calimero DOT vinschen DOT de> <4FBE26C8 DOT 1000008 AT cornell DOT edu> <20120525100321 DOT GF4225 AT calimero DOT vinschen DOT de> <4FBF7EDC DOT 2060502 AT cornell DOT edu> <20120525130314 DOT GJ4225 AT calimero DOT vinschen DOT de>
MIME-Version: 1.0
In-Reply-To: <20120525130314.GJ4225@calimero.vinschen.de>
User-Agent: Mutt/1.5.21 (2010-09-15)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On May 25 15:03, Corinna Vinschen wrote:
> On May 25 08:45, Ken Brown wrote:
> > On 5/25/2012 6:03 AM, Corinna Vinschen wrote:
> > >And then again, do we know if 24.x works on older Cygwin release or
> > >snapshots?  If it's a Cygwin problem, it might help to nail it down.
> > 
> > It works on the 20120111 snapshot but fails on the 20120122
> > snapshot. Thanks for suggesting this.  It should have been the first
> > thing I checked.
> 
> Cool!  That only leaves three checkins to be the culprit.  I'm not
> sure I can get to it over the weekend (and Monday is a holiday here),
> but I'll certainly try to track it down next week.

Ok, I had a look already and I see where the problem is, but that
doesn't mean I understand it yet.

C-g results in calling an emacs signal handler from select.  Up to the
change from 20120122 in select.cc, all select threads have been stopped
before the signal handler is called.  This works fine.

After the change from 20120122, the signal handler is called first, and
only afterwards the select threads are cleaned up.  This results in
starting another pipesel thread and the subsequent crash.

I applied a patch which calls the signal handler after cleanup.  The
downside is that the signal handler is only called if select is called
from the main thread.  A better patch would perhaps be to stop all
threads, call the signal handler, and restart the threads afterwards,
but this is more tricky.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019