emacs-devel
[Top][All Lists]
Advanced

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

Re: Asynchronous DNS


From: Alain Schneble
Subject: Re: Asynchronous DNS
Date: Sun, 21 Feb 2016 11:29:12 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (windows-nt)

Paul Eggert <address@hidden> writes:

> Alain Schneble wrote:
>> But the async-dns implementation that Lars provided uses another
>> approach instead: it polls by calling gai_error (succeed, failed, in
>> progress, ...)  repeatedly from wait_reading_process_output.
>
> You're ahead of me, since I haven't read the implementation. From what
> you say, it appears that Emacs needs to cancel DNS requests that it
> thinks are so old that the answer is not likely to be
> useful. Presumably this could be done just before calling gai_error,
> by calling gai_cancel on the old requests.

That's a good point.  Calling delete-process on a process with a pending
DNS request is the only situation so far where we explicitly cancel the
pending request using gai_cancel.

But I don't think we have to care about timing out DNS requests on our
own.  That should already be handled by the synchronous getaddrinfo that
gets called in the worker threads of getaddrinfo_a.  It should be safe
to assume that the timeouts that getaddrinfo uses were chosen wisely, I
think.  To me, there seems to be no need to introduce yet another
timeout on "our" level.

...and the behavior with the recent patch looks promising :)




reply via email to

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