guile-devel
[Top][All Lists]
Advanced

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

Re: All thread blocked on (accept socket)


From: Christopher Cramer
Subject: Re: All thread blocked on (accept socket)
Date: Tue, 5 Mar 2002 22:46:25 -0600
User-agent: Mutt/1.2.5i

On Tue, Mar 05, 2002 at 09:00:54PM +0000, Neil Jerram wrote:
> Although your patch works for this case, I'm not sure it's the right
> thing to change this in the C code.
> 
> Firstly, one could argue that, with the current CVS code, the choice
> of behaviours is good: if you _want_ the accept to block all threads,
> just call `accept'; if you don't, call `select' first.

I can't imagine why anyone would want to block all the threads on an
accept. But if you did, I think it might be more intuitive to have a
separate procedure (begin-critical-section or something).

> Secondly, if we did make this change, we should logically make it in
> lots of other places as well: connect, recv! etc.

I agree with this, but keep in mind that the current code isn't consistent
either, since reading from an fport already doesn't block. The code
I put into scm_accept() was mostly copied from fport_wait_for_input() in
fports.c.

-- 
Christopher Cramer <address@hidden> <http://www.pyro.net/~crayc/>
Quoi que vous fassiez, écrasez l'infâme, et aimez qui vous aime.
        -- Voltaire



reply via email to

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