[Top][All Lists]

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

Re: Async DNS lookups

From: Stefan Monnier
Subject: Re: Async DNS lookups
Date: Tue, 02 Nov 2010 17:28:13 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

> 3) When getaddrinfo() returns, we do
>    (funcall #'my-callback result my-data)

> But 3) probably needs to be in the same sort of state that timers run
> in, so that we don't have two Emacs Lisp threads running at the same
> time.  Any pointers where to look for how to "halt" the main Emacs
> thread?  Or something?

You can't "halt" the main thread, you can only wait for it to take
a break.  E.g. you could stuff your callback into pending_funcalls.
Of course, pending_funcalls would then need to be protected by a mutex.


reply via email to

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