GNU bug report logs - #19860
25.0.50; One url-retrieve-synchronously call running concurrently with another can freeze it

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Dmitry Gutov <dgutov@HIDDEN>; dated Sat, 14 Feb 2015 00:11:01 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 25 Dec 2015 18:34:32 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Dec 25 13:34:32 2015
Received: from localhost ([127.0.0.1]:35296 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1aCXCC-0001Vu-D8
	for submit <at> debbugs.gnu.org; Fri, 25 Dec 2015 13:34:32 -0500
Received: from hermes.netfonds.no ([80.91.224.195]:53608)
 by debbugs.gnu.org with esmtp (Exim 4.84)
 (envelope-from <larsi@HIDDEN>) id 1aCXCB-0001Vm-AV
 for 19860 <at> debbugs.gnu.org; Fri, 25 Dec 2015 13:34:31 -0500
Received: from 2.150.58.24.tmi.telenormobil.no ([2.150.58.24] helo=mouse)
 by hermes.netfonds.no with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16)
 (Exim 4.72) (envelope-from <larsi@HIDDEN>)
 id 1aCXBq-0002bt-4E; Fri, 25 Dec 2015 19:34:10 +0100
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Dmitry Gutov <dgutov@HIDDEN>
Subject: Re: bug#19860: 25.0.50;
 One url-retrieve-synchronously call running concurrently with another
 can freeze it
References: <86bnkxnyju.fsf@HIDDEN>
Date: Fri, 25 Dec 2015 19:34:09 +0100
In-Reply-To: <86bnkxnyju.fsf@HIDDEN> (Dmitry Gutov's message of "Sat, 14
 Feb 2015 02:09:57 +0200")
Message-ID: <87io3mxtr2.fsf@HIDDEN>
User-Agent: Gnus/5.130014 (Ma Gnus v0.14) Emacs/25.1.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-MailScanner-ID: 1aCXBq-0002bt-4E
X-Netfonds-MailScanner: Found to be clean
X-Netfonds-MailScanner-From: larsi@HIDDEN
MailScanner-NULL-Check: 1451673250.49926@d0k3I5L701/63kr/Puc3Zw
X-Spam-Status: No
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 19860
Cc: 19860 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

Dmitry Gutov <dgutov@HIDDEN> writes:

> This applies both to master and emacs-24 (with a caveat).
>
> With sufficiently suitable server, calling long-ops-now or long-ops-idle
> can lead to the "outer" request never returning:
>
> (defun long-ops-idle ()
>   (interactive)
>   (run-with-idle-timer 0.2 nil #'long-outer-op)
>   (run-with-idle-timer 0.5 nil #'long-inner-op))
>
> (defun long-ops-now ()
>   (interactive)
>   (run-with-timer 0.2 nil #'long-inner-op)
>   (long-outer-op))
>
> (defun long-outer-op ()
>   (message "retrieving outer")
>   (url-retrieve-synchronously "http://localhost:9292")
>   (message "outer retrieved"))
>
> (defun long-inner-op ()
>   (message "retrieving inner")
>   (url-retrieve-synchronously "http://localhost:9292")
>   (message "inner retrieved"))
>
> The window freezes, the last message in the echo area being "inner
> retrieved" (but C-g breaks out of it, and if we're calling
> `long-ops-idle', the "outer" request succeeds, too).

It's unclear from the bug thread whether this is still a problem or
not...  Are you still seeing this?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 26 Apr 2015 21:47:43 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Apr 26 17:47:43 2015
Received: from localhost ([127.0.0.1]:40703 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YmUOs-00037x-St
	for submit <at> debbugs.gnu.org; Sun, 26 Apr 2015 17:47:43 -0400
Received: from smtp.cs.ucla.edu ([131.179.128.62]:51339)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <eggert@HIDDEN>) id 1YmUOq-00037i-VN
 for 19860 <at> debbugs.gnu.org; Sun, 26 Apr 2015 17:47:41 -0400
Received: from localhost (localhost.localdomain [127.0.0.1])
 by smtp.cs.ucla.edu (Postfix) with ESMTP id 39A4AA60016;
 Sun, 26 Apr 2015 14:47:35 -0700 (PDT)
X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu
Received: from smtp.cs.ucla.edu ([127.0.0.1])
 by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id oO-rBn4O2tOA; Sun, 26 Apr 2015 14:47:34 -0700 (PDT)
Received: from [192.168.1.9] (pool-100-32-155-148.lsanca.fios.verizon.net
 [100.32.155.148])
 by smtp.cs.ucla.edu (Postfix) with ESMTPSA id DCD66A6000A;
 Sun, 26 Apr 2015 14:47:34 -0700 (PDT)
Message-ID: <553D5CF6.50900@HIDDEN>
Date: Sun, 26 Apr 2015 14:47:34 -0700
From: Paul Eggert <eggert@HIDDEN>
Organization: UCLA Computer Science Department
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:31.0) Gecko/20100101 Thunderbird/31.6.0
MIME-Version: 1.0
To: Dmitry Gutov <dgutov@HIDDEN>, 19860 <at> debbugs.gnu.org
Subject: Re: bug#19860: 25.0.50; One url-retrieve-synchronously call running
 concurrently with another can freeze it
References: <86bnkxnyju.fsf@HIDDEN>
 <553A3489.6080504@HIDDEN>	<553C2118.4080106@HIDDEN>
 <553C6892.9080901@HIDDEN> <553C7369.1060003@HIDDEN>
 <553D041C.6090003@HIDDEN>
In-Reply-To: <553D041C.6090003@HIDDEN>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 19860
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)

Dmitry Gutov wrote:
> Do you think the Lisp code is at fault there?

Sorry, I don't know.  I did not look at the Lisp code.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 26 Apr 2015 15:28:42 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Apr 26 11:28:42 2015
Received: from localhost ([127.0.0.1]:40545 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YmOU5-0008RB-Om
	for submit <at> debbugs.gnu.org; Sun, 26 Apr 2015 11:28:42 -0400
Received: from mail-wi0-f177.google.com ([209.85.212.177]:37040)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <raaahh@HIDDEN>) id 1YmOU3-0008Qx-Oc
 for 19860 <at> debbugs.gnu.org; Sun, 26 Apr 2015 11:28:40 -0400
Received: by widdi4 with SMTP id di4so65520687wid.0
 for <19860 <at> debbugs.gnu.org>; Sun, 26 Apr 2015 08:28:34 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=sender:message-id:date:from:user-agent:mime-version:to:subject
 :references:in-reply-to:content-type:content-transfer-encoding;
 bh=tZ1FCNwzxbWtwztQ5YPdHkVG4i2fZl5OTn6rCFWBqRs=;
 b=LU+lUS3+dqD5zdGm6uQTzcAx72Ycw6jN2p3PFRv7aEQY5gVU3xrQEHzc3l1YwPPDst
 HkOmlyDL9q0HXH52zHY7ZQ3llMJTKiFg/AuQcgyX+ySVbzV6YimsJFafFfa+mU+DyOC1
 PadIdELnIEKbmMZRof85ny92AqMlOPu4XmtmHNxUH5bg8lDy8KiynRc+j37JQVma0Vuy
 Eiffzi0COz48xpYhtk6GZ6duQZRS6qEi6JCJS51WEGHRkuvZYheBVNZ0kHk+8ZM3VkUL
 aWd08ZFW4SCaKVHPKhMBcJPzAdi/vjqmaeNMaSf+LUoBayUOFcwb3CfyVEMYCLOQUpLE
 /MKA==
X-Received: by 10.180.93.36 with SMTP id cr4mr13054465wib.61.1430062114225;
 Sun, 26 Apr 2015 08:28:34 -0700 (PDT)
Received: from [192.168.1.2] ([82.102.93.54])
 by mx.google.com with ESMTPSA id gu7sm7705327wib.21.2015.04.26.08.28.32
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Sun, 26 Apr 2015 08:28:34 -0700 (PDT)
Message-ID: <553D041C.6090003@HIDDEN>
Date: Sun, 26 Apr 2015 18:28:28 +0300
From: Dmitry Gutov <dgutov@HIDDEN>
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:36.0) Gecko/20100101 Thunderbird/36.0
MIME-Version: 1.0
To: Paul Eggert <eggert@HIDDEN>, 19860 <at> debbugs.gnu.org
Subject: Re: bug#19860: 25.0.50; One url-retrieve-synchronously call
 running concurrently with another can freeze it
References: <86bnkxnyju.fsf@HIDDEN>
 <553A3489.6080504@HIDDEN>	<553C2118.4080106@HIDDEN>
 <553C6892.9080901@HIDDEN> <553C7369.1060003@HIDDEN>
In-Reply-To: <553C7369.1060003@HIDDEN>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 19860
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

On 04/26/2015 08:11 AM, Paul Eggert wrote:

> OK, but in that case I don't see the relevance of commit
> 12dc5429352223f7ba8314d2e16177036a762733.  I get similar symptoms when I
> run Emacs 24.3, which predates that commit.

Fixing the regression was useful by itself, but whether the nearby code 
is relevant for the remaining problem, I'm indeed not sure.

Do you think the Lisp code is at fault there?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 26 Apr 2015 15:02:11 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Apr 26 11:02:10 2015
Received: from localhost ([127.0.0.1]:40527 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YmO4Q-0007qH-CK
	for submit <at> debbugs.gnu.org; Sun, 26 Apr 2015 11:02:10 -0400
Received: from mtaout29.012.net.il ([80.179.55.185]:52025)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <eliz@HIDDEN>) id 1YmO4N-0007q3-SW
 for 19860 <at> debbugs.gnu.org; Sun, 26 Apr 2015 11:02:08 -0400
Received: from conversion-daemon.mtaout29.012.net.il by mtaout29.012.net.il
 (HyperSendmail v2007.08) id <0NNF006005LYJ000@HIDDEN> for
 19860 <at> debbugs.gnu.org; Sun, 26 Apr 2015 18:00:38 +0300 (IDT)
Received: from HOME-C4E4A596F7 ([87.69.4.28]) by mtaout29.012.net.il
 (HyperSendmail v2007.08) with ESMTPA id
 <0NNF00OPB5P2AA60@HIDDEN>; Sun, 26 Apr 2015 18:00:38 +0300 (IDT)
Date: Sun, 26 Apr 2015 18:01:49 +0300
From: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#19860: 25.0.50;
 One url-retrieve-synchronously call running concurrently with
 another	can freeze it
In-reply-to: <553C6892.9080901@HIDDEN>
X-012-Sender: halo1@HIDDEN
To: Dmitry Gutov <dgutov@HIDDEN>
Message-id: <834mo3x7aa.fsf@HIDDEN>
References: <86bnkxnyju.fsf@HIDDEN> <553A3489.6080504@HIDDEN>
 <553C2118.4080106@HIDDEN> <553C6892.9080901@HIDDEN>
X-Spam-Score: 1.0 (+)
X-Debbugs-Envelope-To: 19860
Cc: 19860 <at> debbugs.gnu.org, eggert@HIDDEN
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
Reply-To: Eli Zaretskii <eliz@HIDDEN>
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 1.0 (+)

> Date: Sun, 26 Apr 2015 07:24:50 +0300
> From: Dmitry Gutov <dgutov@HIDDEN>
> 
> On 04/26/2015 02:19 AM, Paul Eggert wrote:
> 
> > Thanks for doing all that legwork.  It let me reproduce the problem and
> > come up with a simple fix that works for me.  I installed the attached
> > patch.
> 
> Thank you for fixing the regression, that should help with the project 
> it manifested in.

It looks like this also fixed bug#20207 and #19729, so I think we can
close them.  Dmitry, can you verify that they are solved for you as
well?

Thanks, Paul.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 26 Apr 2015 05:11:27 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Apr 26 01:11:27 2015
Received: from localhost ([127.0.0.1]:40106 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YmEqk-0000Cy-R9
	for submit <at> debbugs.gnu.org; Sun, 26 Apr 2015 01:11:27 -0400
Received: from smtp.cs.ucla.edu ([131.179.128.62]:55055)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <eggert@HIDDEN>) id 1YmEqh-0000Cg-JU
 for 19860 <at> debbugs.gnu.org; Sun, 26 Apr 2015 01:11:24 -0400
Received: from localhost (localhost.localdomain [127.0.0.1])
 by smtp.cs.ucla.edu (Postfix) with ESMTP id 5162B39E801C;
 Sat, 25 Apr 2015 22:11:17 -0700 (PDT)
X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu
Received: from smtp.cs.ucla.edu ([127.0.0.1])
 by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id KDqX4WEu9wHh; Sat, 25 Apr 2015 22:11:16 -0700 (PDT)
Received: from [192.168.1.9] (pool-100-32-155-148.lsanca.fios.verizon.net
 [100.32.155.148])
 by smtp.cs.ucla.edu (Postfix) with ESMTPSA id 66D9339E801B;
 Sat, 25 Apr 2015 22:11:16 -0700 (PDT)
Message-ID: <553C7369.1060003@HIDDEN>
Date: Sat, 25 Apr 2015 22:11:05 -0700
From: Paul Eggert <eggert@HIDDEN>
Organization: UCLA Computer Science Department
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:31.0) Gecko/20100101 Thunderbird/31.6.0
MIME-Version: 1.0
To: Dmitry Gutov <dgutov@HIDDEN>, 19860 <at> debbugs.gnu.org
Subject: Re: bug#19860: 25.0.50; One url-retrieve-synchronously call running
 concurrently with another can freeze it
References: <86bnkxnyju.fsf@HIDDEN> <553A3489.6080504@HIDDEN>
 <553C2118.4080106@HIDDEN> <553C6892.9080901@HIDDEN>
In-Reply-To: <553C6892.9080901@HIDDEN>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 19860
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)

Dmitry Gutov wrote:
> However, in certain conditions the bug still reproduces

OK, but in that case I don't see the relevance of commit 
12dc5429352223f7ba8314d2e16177036a762733.  I get similar symptoms when I run 
Emacs 24.3, which predates that commit.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 26 Apr 2015 04:30:19 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Apr 26 00:30:19 2015
Received: from localhost ([127.0.0.1]:40102 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YmECw-0007R5-G5
	for submit <at> debbugs.gnu.org; Sun, 26 Apr 2015 00:30:19 -0400
Received: from mail-wi0-f180.google.com ([209.85.212.180]:33716)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <raaahh@HIDDEN>) id 1YmECo-0007QQ-DE
 for 19860 <at> debbugs.gnu.org; Sun, 26 Apr 2015 00:30:12 -0400
Received: by wiax7 with SMTP id x7so60569286wia.0
 for <19860 <at> debbugs.gnu.org>; Sat, 25 Apr 2015 21:30:04 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=sender:message-id:date:from:user-agent:mime-version:to:subject
 :references:in-reply-to:content-type:content-transfer-encoding;
 bh=pG7kSTn0gcW7WLfa98Do9Yj8ATQ1x/1SAVwZXjlDWLE=;
 b=z7L6Uhzllh+o685KNFSga7gW9r9XqKpsiASFMaOgNWHYPiKRB7YlfSA3LE0i3+bjsg
 JbHx8etLiHShhS4dYIOMBYVvAnQtMg8xWGWloGWgfcnhRcR9G2/qaW91ATBOvtpB7TGG
 T1fqlGQcCba+dz0rNO6ahzpreEBu00EvEmhU9zGPhlPlPZVRBMmIcPcUC7NOVLU6iFYL
 Fi6qO1YinBrTtyMZdKc77qQRq1Rlms8bLI8K6sEN5XVURvyyccDYXEOqysxELtX/MHw3
 RqBKQHaiUqcudD2Ryb7ULfoEJrvHmMn4X2kWSAspyw1FiKM/mVXS+XrVg/3X10C+iAYn
 lPSQ==
X-Received: by 10.180.101.98 with SMTP id ff2mr9773325wib.15.1430022604652;
 Sat, 25 Apr 2015 21:30:04 -0700 (PDT)
Received: from [192.168.1.2] ([82.102.93.54])
 by mx.google.com with ESMTPSA id w5sm5802697wiz.11.2015.04.25.21.30.04
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Sat, 25 Apr 2015 21:30:04 -0700 (PDT)
Message-ID: <553C69C9.8090500@HIDDEN>
Date: Sun, 26 Apr 2015 07:30:01 +0300
From: Dmitry Gutov <dgutov@HIDDEN>
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:36.0) Gecko/20100101 Thunderbird/36.0
MIME-Version: 1.0
To: 19860 <at> debbugs.gnu.org, eggert@HIDDEN
Subject: Re: bug#19860: 25.0.50; One url-retrieve-synchronously call
 running concurrently with another can freeze it
References: <86bnkxnyju.fsf@HIDDEN>
 <553A3489.6080504@HIDDEN>	<553C2118.4080106@HIDDEN>
 <553C6892.9080901@HIDDEN>
In-Reply-To: <553C6892.9080901@HIDDEN>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 19860
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

On 04/26/2015 07:24 AM, Dmitry Gutov wrote:

> (basically,
> using the 4-line server written in Ruby, which sends "Connection:
> Keep-Alive" at the end).

And inded, (setq url-http-attempt-keepalives nil) makes the problem go away.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 26 Apr 2015 04:25:03 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Apr 26 00:25:03 2015
Received: from localhost ([127.0.0.1]:40096 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YmE7p-0007H8-7u
	for submit <at> debbugs.gnu.org; Sun, 26 Apr 2015 00:25:02 -0400
Received: from mail-wi0-f172.google.com ([209.85.212.172]:38072)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <raaahh@HIDDEN>) id 1YmE7n-0007Go-8z
 for 19860 <at> debbugs.gnu.org; Sun, 26 Apr 2015 00:24:59 -0400
Received: by wiun10 with SMTP id n10so57290597wiu.1
 for <19860 <at> debbugs.gnu.org>; Sat, 25 Apr 2015 21:24:53 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=sender:message-id:date:from:user-agent:mime-version:to:subject
 :references:in-reply-to:content-type:content-transfer-encoding;
 bh=PteOQMiuHvWzoyzc84rKQKI6OTu7Npr7zzIUMOCKDbs=;
 b=jqblFXxFfbnY5inZiG0ykFFR0+4zXZFmrO1E3bJUaSDPSNQ5GIAdO+8anD/3bHT032
 MaBJ24Bfyx88ktKbTevY4110O8p7Kko4d2xJPGwt6mADIXu4pvFesuZOPGJUpGbj9kVW
 Lx67YYtVj39hi6Sc1o+6UsPlz4AVkFm9E8jQyJ4n60kZNgtecfWCEv4kKDLRJGG9E6Dd
 6OCO4ciZn1xTBQwf9oq9rQ5cPm2xyVYGwr/zeMecVxz7E4aGgm1EsdrgAG2/BNKkCxHz
 duY6JNktTTMk+4H/P2VQoH4/65M7WYIwD4ZatznAlsuIum/3QA9qWI/BMmfBqKFjBWo4
 ms5Q==
X-Received: by 10.180.105.193 with SMTP id go1mr9545338wib.92.1430022293761;
 Sat, 25 Apr 2015 21:24:53 -0700 (PDT)
Received: from [192.168.1.2] ([82.102.93.54])
 by mx.google.com with ESMTPSA id e2sm5804035wij.5.2015.04.25.21.24.53
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Sat, 25 Apr 2015 21:24:53 -0700 (PDT)
Message-ID: <553C6892.9080901@HIDDEN>
Date: Sun, 26 Apr 2015 07:24:50 +0300
From: Dmitry Gutov <dgutov@HIDDEN>
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:36.0) Gecko/20100101 Thunderbird/36.0
MIME-Version: 1.0
To: 19860 <at> debbugs.gnu.org, eggert@HIDDEN
Subject: Re: bug#19860: 25.0.50; One url-retrieve-synchronously call
 running concurrently with another can freeze it
References: <86bnkxnyju.fsf@HIDDEN> <553A3489.6080504@HIDDEN>
 <553C2118.4080106@HIDDEN>
In-Reply-To: <553C2118.4080106@HIDDEN>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 19860
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

On 04/26/2015 02:19 AM, Paul Eggert wrote:

> Thanks for doing all that legwork.  It let me reproduce the problem and
> come up with a simple fix that works for me.  I installed the attached
> patch.

Thank you for fixing the regression, that should help with the project 
it manifested in.

However, in certain conditions the bug still reproduces, both in 
emacs-24 and master, as described in the original report (basically, 
using the 4-line server written in Ruby, which sends "Connection: 
Keep-Alive" at the end).

Please let me know if you're having problems reproducing it locally.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.
Did not alter fixed versions and reopened. Request was from Debbugs Internal Request <help-debbugs@HIDDEN> to internal_control <at> debbugs.gnu.org. Full text available.

Message received at 19860-done <at> debbugs.gnu.org:


Received: (at 19860-done) by debbugs.gnu.org; 25 Apr 2015 23:20:10 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Apr 25 19:20:10 2015
Received: from localhost ([127.0.0.1]:40022 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1Ym9Mm-0006eH-LD
	for submit <at> debbugs.gnu.org; Sat, 25 Apr 2015 19:20:09 -0400
Received: from smtp.cs.ucla.edu ([131.179.128.62]:46548)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <eggert@HIDDEN>) id 1Ym9Mj-0006dj-B0
 for 19860-done <at> debbugs.gnu.org; Sat, 25 Apr 2015 19:20:06 -0400
Received: from localhost (localhost.localdomain [127.0.0.1])
 by smtp.cs.ucla.edu (Postfix) with ESMTP id A6BC639E8014;
 Sat, 25 Apr 2015 16:19:58 -0700 (PDT)
X-Virus-Scanned: amavisd-new at smtp.cs.ucla.edu
Received: from smtp.cs.ucla.edu ([127.0.0.1])
 by localhost (smtp.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10024)
 with ESMTP id NpWpIAomj27R; Sat, 25 Apr 2015 16:19:57 -0700 (PDT)
Received: from [192.168.1.9] (pool-100-32-155-148.lsanca.fios.verizon.net
 [100.32.155.148])
 by smtp.cs.ucla.edu (Postfix) with ESMTPSA id B45EB39E8013;
 Sat, 25 Apr 2015 16:19:57 -0700 (PDT)
Message-ID: <553C2118.4080106@HIDDEN>
Date: Sat, 25 Apr 2015 16:19:52 -0700
From: Paul Eggert <eggert@HIDDEN>
Organization: UCLA Computer Science Department
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:31.0) Gecko/20100101 Thunderbird/31.6.0
MIME-Version: 1.0
To: Dmitry Gutov <dgutov@HIDDEN>, 19860-done <at> debbugs.gnu.org
Subject: Re: bug#19860: 25.0.50; One url-retrieve-synchronously call running
 concurrently with another can freeze it
References: <86bnkxnyju.fsf@HIDDEN> <553A3489.6080504@HIDDEN>
In-Reply-To: <553A3489.6080504@HIDDEN>
Content-Type: multipart/mixed; boundary="------------020608070609030905080107"
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 19860-done
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.3 (--)

This is a multi-part message in MIME format.
--------------020608070609030905080107
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit

Dmitry Gutov wrote:

> 'git bisect' points to 12dc5429352223f7ba8314d2e16177036a762733.
>
> Paul, could you look into this?

Thanks for doing all that legwork.  It let me reproduce the problem and come up 
with a simple fix that works for me.  I installed the attached patch.


--------------020608070609030905080107
Content-Type: text/x-patch;
 name="0001-Don-t-freeze-with-unreadable-processes.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
 filename="0001-Don-t-freeze-with-unreadable-processes.patch"

From 9ca712e2689f1875d7facd229f2cb1916719cf49 Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@HIDDEN>
Date: Sat, 25 Apr 2015 16:16:58 -0700
Subject: [PATCH] Don't freeze with unreadable processes

Don't freeze if an exiting process can't be read from. (Bug#19860).
This fixes a bug I introduced in
2014-07-08T07:24:07Z@eggert@HIDDEN
"* process.c: Add sanity checks for file descriptors."
Dmitry Gutov did most of the legwork in finding the problem.
* src/process.c (wait_reading_process_output):
Treat non-running processes that can't be read from
the same as other non-running processes.
---
 src/process.c | 40 ++++++++++++++++++++++------------------
 1 file changed, 22 insertions(+), 18 deletions(-)

diff --git a/src/process.c b/src/process.c
index c745507..3e04cb7 100644
--- a/src/process.c
+++ b/src/process.c
@@ -4785,37 +4785,41 @@ wait_reading_process_output (intmax_t time_limit, int nsecs, int read_kbd,
       if (wait_proc && wait_proc->raw_status_new)
 	update_status (wait_proc);
       if (wait_proc
-	  && wait_proc->infd >= 0
 	  && ! EQ (wait_proc->status, Qrun)
 	  && ! EQ (wait_proc->status, Qconnect))
 	{
 	  bool read_some_bytes = false;
 
 	  clear_waiting_for_input ();
-	  XSETPROCESS (proc, wait_proc);
 
-	  /* Read data from the process, until we exhaust it.  */
-	  while (true)
+	  /* If data can be read from the process, do so until exhausted.  */
+	  if (wait_proc->infd >= 0)
 	    {
-	      int nread = read_process_output (proc, wait_proc->infd);
-	      if (nread < 0)
+	      XSETPROCESS (proc, wait_proc);
+
+	      while (true)
 		{
-		  if (errno == EIO || errno == EAGAIN)
-		    break;
+		  int nread = read_process_output (proc, wait_proc->infd);
+		  if (nread < 0)
+		    {
+		    if (errno == EIO || errno == EAGAIN)
+		      break;
 #ifdef EWOULDBLOCK
-		  if (errno == EWOULDBLOCK)
-		    break;
+		    if (errno == EWOULDBLOCK)
+		      break;
 #endif
-		}
-	      else
-		{
-		  if (got_some_input < nread)
-		    got_some_input = nread;
-		  if (nread == 0)
-		    break;
-		  read_some_bytes = true;
+		    }
+		  else
+		    {
+		      if (got_some_input < nread)
+			got_some_input = nread;
+		      if (nread == 0)
+			break;
+		      read_some_bytes = true;
+		    }
 		}
 	    }
+
 	  if (read_some_bytes && do_display)
 	    redisplay_preserve_echo_area (10);
 
-- 
2.1.4


--------------020608070609030905080107--




Notification sent to Dmitry Gutov <dgutov@HIDDEN>:
bug acknowledged by developer. Full text available.
Reply sent to Paul Eggert <eggert@HIDDEN>:
You have taken responsibility. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 24 Apr 2015 12:18:34 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Apr 24 08:18:33 2015
Received: from localhost ([127.0.0.1]:38437 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YlcYz-00060S-Bh
	for submit <at> debbugs.gnu.org; Fri, 24 Apr 2015 08:18:33 -0400
Received: from mail-wi0-f179.google.com ([209.85.212.179]:36403)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <raaahh@HIDDEN>) id 1YlcYw-00060E-Ux
 for 19860 <at> debbugs.gnu.org; Fri, 24 Apr 2015 08:18:31 -0400
Received: by wizk4 with SMTP id k4so19713971wiz.1
 for <19860 <at> debbugs.gnu.org>; Fri, 24 Apr 2015 05:18:25 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject
 :references:in-reply-to:content-type:content-transfer-encoding;
 bh=TP9qtjhYvA6NQQ5YcvdtV3cz6cOGaddX+1tjkMnHfUk=;
 b=nUgx5RHfAxQ6JpzrMLqo8IHAlRBR6LJ4Mbb4GgAQXtXUkg7Cyv07R0vjcU9pGfxXSz
 xCZcpiiXNjEbBQ3s9oSfSAAqNMBIW9DPvrqj+ugAam2IzRMSpxT4cy14sb8obrZQZGaH
 t2mNjRSIftpMQa9bWB4huPCg7/ntcaf4d2Y6pjPIe1IzjU45MW78dKf/0OyqfyC4k1WQ
 CS5cEbQ/0UH4ZZxviYaFfuk3aQmzlWjBmRwWffqIgcw5x/XivZDcq48Hqvn0ZFRiXx6G
 KUYjN5ga6yGW0yEqYkwpWumUacaeIUxGMaboakgh824CFEVSwnmGZM6QtYnXJxCB6ltE
 UN9Q==
X-Received: by 10.194.184.45 with SMTP id er13mr15567141wjc.71.1429877905422; 
 Fri, 24 Apr 2015 05:18:25 -0700 (PDT)
Received: from [192.168.1.2] ([82.102.93.54])
 by mx.google.com with ESMTPSA id qt2sm16674996wjc.7.2015.04.24.05.18.24
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Fri, 24 Apr 2015 05:18:25 -0700 (PDT)
Message-ID: <553A3489.6080504@HIDDEN>
Date: Fri, 24 Apr 2015 15:18:17 +0300
From: Dmitry Gutov <dgutov@HIDDEN>
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:36.0) Gecko/20100101 Thunderbird/36.0
MIME-Version: 1.0
To: 19860 <at> debbugs.gnu.org
Subject: Re: bug#19860: 25.0.50; One url-retrieve-synchronously call
 running concurrently with another can freeze it
References: <86bnkxnyju.fsf@HIDDEN>
In-Reply-To: <86bnkxnyju.fsf@HIDDEN>
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 19860
Cc: Paul Eggert <eggert@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

On 02/14/2015 02:09 AM, Dmitry Gutov wrote:

> The key difference seems to be Keep-Alive (enabled by default by WEBrick
> (Ruby); wsgiref doesn't support it at all). Adding "Connection: close"
> to the Ruby example server makes emacs-24 behave as expected with it.

Like mentioned, when using http://ya.ru/ as the request URL, emacs-24 
doesn't freeze. Fixing that case in master should be a step forward.

'git bisect' points to 12dc5429352223f7ba8314d2e16177036a762733.

Paul, could you look into this?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.
Removed indication that bug 19860 blocks Request was from Dmitry Gutov <raaahh@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 17 Feb 2015 23:25:05 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Feb 17 18:25:05 2015
Received: from localhost ([127.0.0.1]:46697 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YNrVp-0003Sg-22
	for submit <at> debbugs.gnu.org; Tue, 17 Feb 2015 18:25:05 -0500
Received: from mail-we0-f172.google.com ([74.125.82.172]:39559)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <raaahh@HIDDEN>) id 1YNrVl-0003S9-O8
 for 19860 <at> debbugs.gnu.org; Tue, 17 Feb 2015 18:25:03 -0500
Received: by wesx3 with SMTP id x3so1443949wes.6
 for <19860 <at> debbugs.gnu.org>; Tue, 17 Feb 2015 15:24:56 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject
 :references:in-reply-to:content-type:content-transfer-encoding;
 bh=4H5loqvcVKh5HhRp92aLlgKef+CvrMUVZVE7OrPB2dY=;
 b=rUTvlFr5V9sqZ73ijOOVVPit48/2o1Iv54yuYV4qK2ylHw1Ha68pjpvM9Knj0rn+lq
 kt9082NWwnGsQwSDH/VspP/zFTdkutt3A9skvdY4h6MCTQFTPMP+CyjSBz2F4D+LcVJ3
 tu+YATQQ/bZboc2sHjJvbhgEGvWsN9P9ZJQ+i+4m0W+ITsy4Pndj6x88fEmp+UXV+/Zg
 UC0Rq92L0Q/QcOqYQRtE2tjKKDn9bMaihErGengr0jxq4LXoPfLfHrtPefW5CT7PtyZa
 9f8Hz6fccsAem7UN2BDW082c84WQ1CC97XsAyn6wLTEOQXNwb2Jm9CYDrfmMLhkl7eLE
 zRGw==
X-Received: by 10.194.85.129 with SMTP id h1mr31611861wjz.147.1424215496161;
 Tue, 17 Feb 2015 15:24:56 -0800 (PST)
Received: from [192.168.1.2] ([82.102.93.54])
 by mx.google.com with ESMTPSA id y14sm16354916wjr.39.2015.02.17.15.24.55
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Tue, 17 Feb 2015 15:24:55 -0800 (PST)
Message-ID: <54E3CDC6.7040806@HIDDEN>
Date: Wed, 18 Feb 2015 01:24:54 +0200
From: Dmitry Gutov <dgutov@HIDDEN>
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:36.0) Gecko/20100101 Thunderbird/36.0
MIME-Version: 1.0
To: Glenn Morris <rgm@HIDDEN>
Subject: Re: bug#19860: 25.0.50; One url-retrieve-synchronously call
 running concurrently with another can freeze it
References: <86bnkxnyju.fsf@HIDDEN>	<handler.19860.B.142387261510331.ack <at> debbugs.gnu.org>	<54E11B6B.8000408@HIDDEN>
 <54E14128.9010604@HIDDEN> <0gpp982vlb.fsf_-_@HIDDEN>
In-Reply-To: <0gpp982vlb.fsf_-_@HIDDEN>
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 19860
Cc: 19860 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

On 02/17/2015 09:20 PM, Glenn Morris wrote:
>
> You've marked this as blocking the 24.5 release.
> Could you say why? Is it a new issue in 24.4?

No, sorry, it's not. Unblocking. I didn't know, at the time, that 24.5 
will be so soon.

This bug is quite annoying, though, especially on master, where it 
manifests in real-life usage.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 17 Feb 2015 19:20:57 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Feb 17 14:20:56 2015
Received: from localhost ([127.0.0.1]:46590 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YNnhY-00030H-Gz
	for submit <at> debbugs.gnu.org; Tue, 17 Feb 2015 14:20:56 -0500
Received: from fencepost.gnu.org ([208.118.235.10]:43694 ident=Debian-exim)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <rgm@HIDDEN>) id 1YNnhW-000309-HE
 for 19860 <at> debbugs.gnu.org; Tue, 17 Feb 2015 14:20:54 -0500
Received: from rgm by fencepost.gnu.org with local (Exim 4.71)
 (envelope-from <rgm@HIDDEN>)
 id 1YNnhR-0007AO-7N; Tue, 17 Feb 2015 14:20:49 -0500
From: Glenn Morris <rgm@HIDDEN>
To: Dmitry Gutov <dgutov@HIDDEN>
Subject: Re: bug#19860: 25.0.50;
 One url-retrieve-synchronously call running concurrently with another
 can freeze it
References: <86bnkxnyju.fsf@HIDDEN>
 <handler.19860.B.142387261510331.ack <at> debbugs.gnu.org>
 <54E11B6B.8000408@HIDDEN> <54E14128.9010604@HIDDEN>
X-Spook: Firefly Albright John Kerry IDEA Legion of Doom smuggle
X-Ran: v).FOIyV%=C~pI*RM]Rk{wNRw7=.R9]\Gf>{g1CiSW7|=F$&>E>u6=hs)-2*AHSo:LV^HE
X-Hue: magenta
X-Attribution: GM
Date: Tue, 17 Feb 2015 14:20:48 -0500
In-Reply-To: <54E14128.9010604@HIDDEN> (Dmitry Gutov's message of "Mon, 16
 Feb 2015 03:00:24 +0200")
Message-ID: <0gpp982vlb.fsf_-_@HIDDEN>
User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Spam-Score: -5.0 (-----)
X-Debbugs-Envelope-To: 19860
Cc: 19860 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -5.0 (-----)


You've marked this as blocking the 24.5 release.
Could you say why? Is it a new issue in 24.4?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 16 Feb 2015 01:00:37 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Feb 15 20:00:37 2015
Received: from localhost ([127.0.0.1]:45028 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YNA39-0006tr-L9
	for submit <at> debbugs.gnu.org; Sun, 15 Feb 2015 20:00:35 -0500
Received: from mail-wi0-f170.google.com ([209.85.212.170]:45756)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <raaahh@HIDDEN>) id 1YNA36-0006tc-AZ
 for 19860 <at> debbugs.gnu.org; Sun, 15 Feb 2015 20:00:33 -0500
Received: by mail-wi0-f170.google.com with SMTP id hi2so22303950wib.1
 for <19860 <at> debbugs.gnu.org>; Sun, 15 Feb 2015 17:00:26 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=sender:message-id:date:from:user-agent:mime-version:to:subject
 :references:in-reply-to:content-type:content-transfer-encoding;
 bh=JaBEDXknqgeqAWNHnFv+U1kbdMF2x50hhrSR3ANjMrY=;
 b=Hb7OVbRk/mDOC/1UyODu20rh4vOE42PP4+en3vOnlhNfIEL6rV9Lb7kCFtUiIGKlRu
 UdCquXHT+f1pzQJ1EQEOqkkKL74TgbrDlctn+G1I6e2YiLA+ZSfVAFN827RBb6IUIUQz
 FXxZhcyu/RPtLUc2B0vxFXVo4B7baebPcOcsJOzfR3iMX4XPoPqTXHOzFtNiPjN+yxsw
 GliNxE1JZlr56kTNGc41rsYAl8miVFnsMNuz7HLwK+jWBKdGASDUkdqMEpMnp1Rr3fww
 BBjkQlNdEAcOwhHHgoIm9x/VFT73TrIRb3DKe8mRm7IEUZVfeGrSBg4cuXNRhLWsl+vn
 TezQ==
X-Received: by 10.194.189.77 with SMTP id gg13mr43580734wjc.81.1424048426589; 
 Sun, 15 Feb 2015 17:00:26 -0800 (PST)
Received: from [192.168.1.2] ([82.102.93.54])
 by mx.google.com with ESMTPSA id hv5sm20427434wjb.16.2015.02.15.17.00.25
 for <19860 <at> debbugs.gnu.org>
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Sun, 15 Feb 2015 17:00:26 -0800 (PST)
Message-ID: <54E14128.9010604@HIDDEN>
Date: Mon, 16 Feb 2015 03:00:24 +0200
From: Dmitry Gutov <dgutov@HIDDEN>
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:36.0) Gecko/20100101 Thunderbird/36.0
MIME-Version: 1.0
To: 19860 <at> debbugs.gnu.org
Subject: Re: bug#19860: Acknowledgement (25.0.50; One
 url-retrieve-synchronously call running concurrently with another can
 freeze it)
References: <86bnkxnyju.fsf@HIDDEN>	<handler.19860.B.142387261510331.ack <at> debbugs.gnu.org>
 <54E11B6B.8000408@HIDDEN>
In-Reply-To: <54E11B6B.8000408@HIDDEN>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 19860
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

And here's me attaching to that process:

0x00007fae43df32d9 in __pselect (nfds=nfds@entry=14, 
readfds=readfds@entry=0x7fffa07d4370, writefds=0x7fffa07d43f0, 
exceptfds=exceptfds@entry=0x0, timeout=<optimized out>, 
timeout@entry=0x7fffa07d4920,
     sigmask=sigmask@entry=0x0) at ../sysdeps/unix/sysv/linux/pselect.c:77
77	../sysdeps/unix/sysv/linux/pselect.c: No such file or directory.
(gdb) finish
Run till exit from #0  0x00007fae43df32d9 in __pselect 
(nfds=nfds@entry=14, readfds=readfds@entry=0x7fffa07d4370, 
writefds=0x7fffa07d43f0, exceptfds=exceptfds@entry=0x0, 
timeout=<optimized out>,
     timeout@entry=0x7fffa07d4920, sigmask=sigmask@entry=0x0) at 
../sysdeps/unix/sysv/linux/pselect.c:77
0x00000000005b464a in xg_select (fds_lim=14, 
rfds=rfds@entry=0x7fffa07d4940, wfds=0x7fffa07d49c0, 
efds=efds@entry=0x0, timeout=timeout@entry=0x7fffa07d4920, 
sigmask=sigmask@entry=0x0) at xgselect.c:114
114	  nfds = pselect (fds_lim, &all_rfds, have_wfds ? &all_wfds : NULL,
Value returned is $1 = 1
(gdb) finish
Run till exit from #0  0x00000000005b464a in xg_select (fds_lim=14, 
rfds=rfds@entry=0x7fffa07d4940, wfds=0x7fffa07d49c0, 
efds=efds@entry=0x0, timeout=timeout@entry=0x7fffa07d4920,
     sigmask=sigmask@entry=0x0) at xgselect.c:114
0x00000000005836e1 in wait_reading_process_output (time_limit=<optimized 
out>, nsecs=0, read_kbd=read_kbd@entry=0, 
do_display=do_display@entry=false, wait_for_cell=wait_for_cell@entry=0,
     wait_proc=0x351a938, just_wait_proc=0) at process.c:4597
4597		  nfds = xg_select
Value returned is $2 = -1
(gdb) finish
Run till exit from #0  0x00000000005836e1 in wait_reading_process_output 
(time_limit=<optimized out>, nsecs=0, read_kbd=read_kbd@entry=0, 
do_display=do_display@entry=false,
     wait_for_cell=wait_for_cell@entry=0, wait_proc=0x351a938, 
just_wait_proc=0) at process.c:4597





Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.

Message received at 19860 <at> debbugs.gnu.org:


Received: (at 19860) by debbugs.gnu.org; 15 Feb 2015 22:19:37 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sun Feb 15 17:19:37 2015
Received: from localhost ([127.0.0.1]:44964 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YN7XM-0003Gl-9q
	for submit <at> debbugs.gnu.org; Sun, 15 Feb 2015 17:19:36 -0500
Received: from mail-we0-f172.google.com ([74.125.82.172]:32910)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <raaahh@HIDDEN>) id 1YN7XJ-0003GX-Gh
 for 19860 <at> debbugs.gnu.org; Sun, 15 Feb 2015 17:19:34 -0500
Received: by mail-we0-f172.google.com with SMTP id k48so26054947wev.3
 for <19860 <at> debbugs.gnu.org>; Sun, 15 Feb 2015 14:19:27 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=sender:message-id:date:from:user-agent:mime-version:to:subject
 :references:in-reply-to:content-type:content-transfer-encoding;
 bh=xRB8PlFWjMvXsg6yrdciJl8VLUlf4X66TBe7wtKpFdE=;
 b=fGJ9AooeZnysOYSzP5dWEJoNmzrIccx0pXG71PwsmWe81tvuJTNQC9WW1WZ+euYUr8
 IHQx0bMrhChfKDKvDelj+ZQPVgAu3Ccpk8w5h+iVzDPmpZ7lOmRunjgXZct/i/MIj1yA
 GICDzs0YgtdujehWe5RhyWzpBbZDxwRxBVqo+f+q4hRZe4NNnwiSVxWdcIIjahriGgsP
 8PltcwMji6TcXfp1qb6qRkcG8FVawXALTEa0saKPFdLzVmfByNM1Elnr4kPPjDZKzxKP
 YkMeGIjABtK4OrcICYNmEU65ozJSR13Xl+DOQTR7CzGWvQQSnjlPkgovLlos49cFH3qK
 Qi9w==
X-Received: by 10.194.77.99 with SMTP id r3mr42447486wjw.149.1424038767814;
 Sun, 15 Feb 2015 14:19:27 -0800 (PST)
Received: from [192.168.1.2] ([82.102.93.54])
 by mx.google.com with ESMTPSA id dj4sm20036754wjc.13.2015.02.15.14.19.26
 for <19860 <at> debbugs.gnu.org>
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Sun, 15 Feb 2015 14:19:27 -0800 (PST)
Message-ID: <54E11B6B.8000408@HIDDEN>
Date: Mon, 16 Feb 2015 00:19:23 +0200
From: Dmitry Gutov <dgutov@HIDDEN>
User-Agent: Mozilla/5.0 (X11; Linux x86_64;
 rv:36.0) Gecko/20100101 Thunderbird/36.0
MIME-Version: 1.0
To: 19860 <at> debbugs.gnu.org
Subject: Re: bug#19860: Acknowledgement (25.0.50; One
 url-retrieve-synchronously call running concurrently with another can
 freeze it)
References: <86bnkxnyju.fsf@HIDDEN>
 <handler.19860.B.142387261510331.ack <at> debbugs.gnu.org>
In-Reply-To: <handler.19860.B.142387261510331.ack <at> debbugs.gnu.org>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
X-Spam-Score: -0.7 (/)
X-Debbugs-Envelope-To: 19860
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

With debug-on-quit, pressing C-g during the wait yields:

Debugger entered--Lisp error: (quit)
   (condition-case nil (let ((inhibit-quit nil)) (accept-process-output 
proc)) (quit (setq quit-flag t) (eval (quote (ignore nil)))))
   (or (condition-case nil (let ((inhibit-quit nil)) 
(accept-process-output proc)) (quit (setq quit-flag t) (eval (quote 
(ignore nil))))) (null proc))
   (if (or (condition-case nil (let ((inhibit-quit nil)) 
(accept-process-output proc)) (quit (setq quit-flag t) (eval (quote 
(ignore nil))))) (null proc)) nil (if quit-flag (progn (delete-process 
proc))) (setq proc (and (not quit-flag) (get-buffer-process 
asynch-buffer))))
   (if (buffer-local-value (quote url-redirect-buffer) asynch-buffer) 
(setq proc (get-buffer-process (setq asynch-buffer (buffer-local-value 
(quote url-redirect-buffer) asynch-buffer)))) (if (and proc (memq 
(process-status proc) (quote (closed exit signal failed))) (eq proc (or 
(get-buffer-process asynch-buffer) proc))) (progn (delete-process proc) 
(setq retrieval-done t))) (if (or (condition-case nil (let 
((inhibit-quit nil)) (accept-process-output proc)) (quit (setq quit-flag 
t) (eval (quote (ignore nil))))) (null proc)) nil (if quit-flag (progn 
(delete-process proc))) (setq proc (and (not quit-flag) 
(get-buffer-process asynch-buffer)))))
   (while (not retrieval-done) (url-debug (quote retrieval) "Spinning in 
url-retrieve-synchronously: %S (%S)" retrieval-done asynch-buffer) (if 
(buffer-local-value (quote url-redirect-buffer) asynch-buffer) (setq 
proc (get-buffer-process (setq asynch-buffer (buffer-local-value (quote 
url-redirect-buffer) asynch-buffer)))) (if (and proc (memq 
(process-status proc) (quote (closed exit signal failed))) (eq proc (or 
(get-buffer-process asynch-buffer) proc))) (progn (delete-process proc) 
(setq retrieval-done t))) (if (or (condition-case nil (let 
((inhibit-quit nil)) (accept-process-output proc)) (quit (setq quit-flag 
t) (eval (quote ...)))) (null proc)) nil (if quit-flag (progn 
(delete-process proc))) (setq proc (and (not quit-flag) 
(get-buffer-process asynch-buffer))))))
   (let ((proc (get-buffer-process asynch-buffer))) (while (not 
retrieval-done) (url-debug (quote retrieval) "Spinning in 
url-retrieve-synchronously: %S (%S)" retrieval-done asynch-buffer) (if 
(buffer-local-value (quote url-redirect-buffer) asynch-buffer) (setq 
proc (get-buffer-process (setq asynch-buffer (buffer-local-value (quote 
url-redirect-buffer) asynch-buffer)))) (if (and proc (memq 
(process-status proc) (quote (closed exit signal failed))) (eq proc (or 
(get-buffer-process asynch-buffer) proc))) (progn (delete-process proc) 
(setq retrieval-done t))) (if (or (condition-case nil (let (...) 
(accept-process-output proc)) (quit (setq quit-flag t) (eval ...))) 
(null proc)) nil (if quit-flag (progn (delete-process proc))) (setq proc 
(and (not quit-flag) (get-buffer-process asynch-buffer)))))))
   (if (null asynch-buffer) nil (let ((proc (get-buffer-process 
asynch-buffer))) (while (not retrieval-done) (url-debug (quote 
retrieval) "Spinning in url-retrieve-synchronously: %S (%S)" 
retrieval-done asynch-buffer) (if (buffer-local-value (quote 
url-redirect-buffer) asynch-buffer) (setq proc (get-buffer-process (setq 
asynch-buffer (buffer-local-value ... asynch-buffer)))) (if (and proc 
(memq (process-status proc) (quote ...)) (eq proc (or ... proc))) (progn 
(delete-process proc) (setq retrieval-done t))) (if (or (condition-case 
nil (let ... ...) (quit ... ...)) (null proc)) nil (if quit-flag (progn 
(delete-process proc))) (setq proc (and (not quit-flag) 
(get-buffer-process asynch-buffer))))))) asynch-buffer)
   (let ((retrieval-done nil) (asynch-buffer nil)) (setq asynch-buffer 
(url-retrieve url (function (lambda (&rest ignored) (url-debug (quote 
retrieval) "Synchronous fetching done (%S)" (current-buffer)) (setq 
retrieval-done t asynch-buffer (current-buffer)))) nil silent 
inhibit-cookies)) (if (null asynch-buffer) nil (let ((proc 
(get-buffer-process asynch-buffer))) (while (not retrieval-done) 
(url-debug (quote retrieval) "Spinning in url-retrieve-synchronously: %S 
(%S)" retrieval-done asynch-buffer) (if (buffer-local-value (quote 
url-redirect-buffer) asynch-buffer) (setq proc (get-buffer-process (setq 
asynch-buffer ...))) (if (and proc (memq ... ...) (eq proc ...)) (progn 
(delete-process proc) (setq retrieval-done t))) (if (or (condition-case 
nil ... ...) (null proc)) nil (if quit-flag (progn ...)) (setq proc (and 
... ...)))))) asynch-buffer))
   url-retrieve-synchronously("http://xip.io")
   long-outer-op()
   long-ops-now()




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.
Added indication that bug 19860 blocks19758 Request was from Dmitry Gutov <dgutov@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 14 Feb 2015 00:10:15 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Feb 13 19:10:15 2015
Received: from localhost ([127.0.0.1]:42358 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1YMQJK-0002gY-A1
	for submit <at> debbugs.gnu.org; Fri, 13 Feb 2015 19:10:14 -0500
Received: from eggs.gnu.org ([208.118.235.92]:42999)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <raaahh@HIDDEN>) id 1YMQJI-0002gJ-Nr
 for submit <at> debbugs.gnu.org; Fri, 13 Feb 2015 19:10:13 -0500
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <raaahh@HIDDEN>) id 1YMQJC-0000Em-By
 for submit <at> debbugs.gnu.org; Fri, 13 Feb 2015 19:10:07 -0500
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM,
 T_DKIM_INVALID autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:35675)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <raaahh@HIDDEN>) id 1YMQJC-0000DH-8q
 for submit <at> debbugs.gnu.org; Fri, 13 Feb 2015 19:10:06 -0500
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44721)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <raaahh@HIDDEN>) id 1YMQJA-0007Jg-W1
 for bug-gnu-emacs@HIDDEN; Fri, 13 Feb 2015 19:10:06 -0500
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <raaahh@HIDDEN>) id 1YMQJ7-0008WV-OO
 for bug-gnu-emacs@HIDDEN; Fri, 13 Feb 2015 19:10:04 -0500
Received: from mail-wg0-x233.google.com ([2a00:1450:400c:c00::233]:33411)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <raaahh@HIDDEN>) id 1YMQJ7-0008UZ-I3
 for bug-gnu-emacs@HIDDEN; Fri, 13 Feb 2015 19:10:01 -0500
Received: by mail-wg0-f51.google.com with SMTP id y19so19634946wgg.10
 for <bug-gnu-emacs@HIDDEN>; Fri, 13 Feb 2015 16:10:00 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
 h=sender:from:to:subject:date:message-id:mime-version:content-type;
 bh=Orh76VgtGcZZVvQvVLF+dRGqPFdtebLxU3+wkajsGr4=;
 b=CIox0xY6r2XVpO21X2J4VXwctZ5Whb3+C6ISLUQ5vKg+BK+ASHaPh5YoD5acbZE+MS
 xcFNH6wHhqbd6t4hzTugPtvohOYDM8YAh/jObvNS5t3b7LNXJ0Rwbxi/CTu8SY2VdI2G
 XntYXZjZyfIZz6JOw372bRXXX8kBiJkYbImqzD0sioCyjLDFmdoLFd95C2D1cPoWFe8e
 4x/d74E589B9CIC6waOyb2mlNvHGcVyHF+LtUo0+iO009tmwe5S9KI+B6d1JFicm6Cdf
 rbys/ZPLvkVwom3AiPlhzbdl0hKjiaAB2BAGdcyH92uXHJVqB9W9/b4vS9tUWhJ0HlbR
 uFZw==
X-Received: by 10.180.21.162 with SMTP id w2mr11908805wie.42.1423872600828;
 Fri, 13 Feb 2015 16:10:00 -0800 (PST)
Received: from axl (static-nbl2-118.cytanet.com.cy. [212.31.107.118])
 by mx.google.com with ESMTPSA id g10sm4889563wic.7.2015.02.13.16.09.59
 for <bug-gnu-emacs@HIDDEN>
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Fri, 13 Feb 2015 16:10:00 -0800 (PST)
From: Dmitry Gutov <dgutov@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: 25.0.50;
 One url-retrieve-synchronously call running concurrently with another
 can freeze it
Date: Sat, 14 Feb 2015 02:09:57 +0200
Message-ID: <86bnkxnyju.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -4.0 (----)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -4.0 (----)

This applies both to master and emacs-24 (with a caveat).

With sufficiently suitable server, calling long-ops-now or long-ops-idle
can lead to the "outer" request never returning:

--8<---------------cut here---------------start------------->8---
(defun long-ops-idle ()
  (interactive)
  (run-with-idle-timer 0.2 nil #'long-outer-op)
  (run-with-idle-timer 0.5 nil #'long-inner-op))

(defun long-ops-now ()
  (interactive)
  (run-with-timer 0.2 nil #'long-inner-op)
  (long-outer-op))

(defun long-outer-op ()
  (message "retrieving outer")
  (url-retrieve-synchronously "http://localhost:9292")
  (message "outer retrieved"))

(defun long-inner-op ()
  (message "retrieving inner")
  (url-retrieve-synchronously "http://localhost:9292")
  (message "inner retrieved"))
--8<---------------cut here---------------end--------------->8---

The window freezes, the last message in the echo area being "inner
retrieved" (but C-g breaks out of it, and if we're calling
`long-ops-idle', the "outer" request succeeds, too).

It doesn't happen with just any web server, though. I can reproduce it
using both master and emacs-24 using this Ruby server:

--8<---------------cut here---------------start------------->8---
run proc { |env|
  sleep 1
  [200, {'Content-Type' => 'text/plain'}, [""]]
}
--8<---------------cut here---------------end--------------->8---

Save it as test.ru and launch with 'rackup test.ru'.

But only with master using this Python server (an example for those who
don't have Ruby installed):

--8<---------------cut here---------------start------------->8---
from wsgiref.util import setup_testing_defaults
from wsgiref.simple_server import make_server
import time

def simple_app(environ, start_response):
    setup_testing_defaults(environ)

    status = '200 OK'
    headers = [('Content-type', 'text/plain')]

    time.sleep(1)

    start_response(status, headers)

    return ""

httpd = make_server('', 9292, simple_app)
print "Serving on port 9292..."
httpd.serve_forever()
--8<---------------cut here---------------end--------------->8---

Save it as server.py, and launch with 'python server.py'.

The key difference seems to be Keep-Alive (enabled by default by WEBrick
(Ruby); wsgiref doesn't support it at all). Adding "Connection: close"
to the Ruby example server makes emacs-24 behave as expected with it.

And someone who doesn't want to run the server can also try the
following URLs with master: http://xip.io/ and http://ya.ru/. When
calling xip.io, the outer request eventually returns, but much later
than expected; when calling ya.ru, it doesn't.

The present bug report is based on this long-standing issue, which I
haven't been able to reliably reproduce until now:
https://github.com/dgutov/robe/issues/36

In GNU Emacs 25.0.50.5 (x86_64-unknown-linux-gnu, GTK+ Version 3.12.2)
 of 2015-02-13 on axl
Repository revision: 69e38a5b1fdb5ac20440b6ce7ba1fc2cd575f4e6
Windowing system distributor `The X.Org Foundation', version 11.0.11601901
System Description:	Ubuntu 14.10




Acknowledgement sent to Dmitry Gutov <dgutov@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#19860; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Fri, 25 Dec 2015 18:45:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.