From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andy Moreton Newsgroups: gmane.emacs.bugs Subject: bug#12832: 24.3.50; Emacs lockup when idle Date: Wed, 14 Nov 2012 12:44:39 +0000 Message-ID: <50A39237.3090302@gmail.com> References: <838vac12kn.fsf@gnu.org> <509BFAE7.8020205@gmail.com> <83liebyu9t.fsf@gnu.org> <509CDF7F.2000409@gmail.com> <83ip9fyqmy.fsf@gnu.org> <83390izlxm.fsf@gnu.org> <509D4DAC.1060901@gmail.com> <83pq3hvet0.fsf@gnu.org> <509BAC2E.2000702@gmail.com> <80r4nxsl1s.fsf@somewhere.org> <83lie5vbot.fsf@gnu.org> <50A2585A.3050008@gmail.com> <83ip99v8h5.fsf@gnu.org> <50A26E9E.4020405@gmail.com> <83ehjxv3gv.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1352897135 12757 80.91.229.3 (14 Nov 2012 12:45:35 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 14 Nov 2012 12:45:35 +0000 (UTC) Cc: fni@missioncriticalit.com, 12832@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Nov 14 13:45:44 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TYcLg-0004tg-1h for geb-bug-gnu-emacs@m.gmane.org; Wed, 14 Nov 2012 13:45:44 +0100 Original-Received: from localhost ([::1]:35526 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TYcLW-0007kZ-DP for geb-bug-gnu-emacs@m.gmane.org; Wed, 14 Nov 2012 07:45:34 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:50816) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TYcLS-0007kD-1m for bug-gnu-emacs@gnu.org; Wed, 14 Nov 2012 07:45:33 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TYcLO-00037h-Vm for bug-gnu-emacs@gnu.org; Wed, 14 Nov 2012 07:45:29 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:59063) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TYcLO-00037d-RH for bug-gnu-emacs@gnu.org; Wed, 14 Nov 2012 07:45:26 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1TYcLx-0001BZ-IH for bug-gnu-emacs@gnu.org; Wed, 14 Nov 2012 07:46:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Andy Moreton Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 14 Nov 2012 12:46:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 12832 X-GNU-PR-Package: emacs,w32 X-GNU-PR-Keywords: Original-Received: via spool by 12832-submit@debbugs.gnu.org id=B12832.13528971234514 (code B ref 12832); Wed, 14 Nov 2012 12:46:01 +0000 Original-Received: (at 12832) by debbugs.gnu.org; 14 Nov 2012 12:45:23 +0000 Original-Received: from localhost ([127.0.0.1]:41081 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TYcLL-0001Ak-F0 for submit@debbugs.gnu.org; Wed, 14 Nov 2012 07:45:23 -0500 Original-Received: from mail-wg0-f46.google.com ([74.125.82.46]:57802) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TYcLJ-0001Ab-Rz for 12832@debbugs.gnu.org; Wed, 14 Nov 2012 07:45:22 -0500 Original-Received: by mail-wg0-f46.google.com with SMTP id dt12so176904wgb.15 for <12832@debbugs.gnu.org>; Wed, 14 Nov 2012 04:44:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=JE3N/o+CR6IQqr0poNrWLTXOz4eklriT11dAKVODowI=; b=beIU97cfYM/5sMP/qISo+vM4i7hZ4bldHlCQuPboaG9ITEZwMZgkMjIyql1Z4/YVG2 bP9ksIp1WQhV5pr9OVxxQ6QaHp5/X36IpTzc7kLzo9D03lGP4xi6y/EBuVWAB52EcdL/ sG62KGFeMRf/5iQFsF5LIdlD7GCwD20b61o2JeiqI519GYQVCEdBrq+wllc1q+HdFx57 KNgAr/Ur6j63aFNgbytKe51pd5R/8ssi/78arxpu+tuzVJTprxKE6afGipMhlG4Y2z/l Ly51gkQ5JuixuZY57xQ8xW+biYgPLj0WmmbbjobYKcsq/FMvyVyJWyVWz07zDtEL/oGb FEuw== Original-Received: by 10.180.24.4 with SMTP id q4mr25761945wif.19.1352897085534; Wed, 14 Nov 2012 04:44:45 -0800 (PST) Original-Received: from [10.17.20.82] (uk.solarflare.com. [193.34.186.16]) by mx.google.com with ESMTPS id d16sm6402992wiw.8.2012.11.14.04.44.40 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 14 Nov 2012 04:44:42 -0800 (PST) User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:16.0) Gecko/20121026 Thunderbird/16.0.2 In-Reply-To: <83ehjxv3gv.fsf@gnu.org> X-Spam-Score: 0.1 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-Spam-Score: 0.1 (/) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:66917 Archived-At: On 13/11/2012 17:04, Eli Zaretskii wrote: > Can you please try the patch below and see if it prevents the > lock-ups? > > === modified file 'src/w32proc.c' > --- src/w32proc.c 2012-11-05 03:18:32 +0000 > +++ src/w32proc.c 2012-11-13 16:59:53 +0000 > @@ -431,13 +431,24 @@ timer_loop (LPVOID arg) > /* Simulate a signal delivered to the thread which installed > the timer, by suspending that thread while the handler > runs. */ > - DWORD result = SuspendThread (itimer->caller_thread); > + DWORD result; > + > + if (dwMainThreadId) > + enter_crit (); > + result = SuspendThread (itimer->caller_thread); > > if (result == (DWORD)-1) > - return 2; > + { > + if (dwMainThreadId) > + leave_crit (); > + return 2; > + } > > handler (sig); > ResumeThread (itimer->caller_thread); > + > + if (dwMainThreadId) > + leave_crit (); > } > > /* Update expiration time and loop. */ > I applied this to emacs-24 branch (r110866) this morning. So far I've not seen a lockup, but I'll to run it for a day or two to be sure. AndyM