emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: url-retrieve may cause hang


From: Magnus Henoch
Subject: Re: url-retrieve may cause hang
Date: Tue, 17 Oct 2006 02:42:44 +0200
User-agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (berkeley-unix)

David Reitter <address@hidden> writes:

> url-retrieve may cause Emacs to hang for around 3 minutes when the
> firewall is configured to delay packets. This is unwanted behavior,
> as url-retrieve claims to work asynchronously.
>
> Example:
>
> Configure firewall to delay (rather than deny) packets:
>
> sudo ipfw add 1 pipe 7 tcp from any to any 80
>
> (url-retrieve  "http://www.google.com"; 'print)
> % or use url-http for this
>
> -> Hang until time-out (several minutes).

The problem is in url-open-stream in url-gw.el.  The URL library uses
open-network-stream, which blocks until the connection is established
(or times out, in this case).  url-retrieve is indeed asynchronous
when the connection is established.

It should use make-network-process with appropriate arguments, and set
up sentinels and such, which is the first thing I intend to do after
the release, as it might be tricky to get it right.  Or should I
change my plan and do it now?

Magnus





reply via email to

[Prev in Thread] Current Thread [Next in Thread]