guile-user
[Top][All Lists]
Advanced

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

Re: recv! and thread


From: William Xu
Subject: Re: recv! and thread
Date: Sat, 11 Mar 2006 03:41:57 +0800
User-agent: Gnus/5.110004 (No Gnus v0.4) Emacs/22.0.50 (gnu/linux)

Kevin Ryde <address@hidden> writes:

> William Xu <address@hidden> writes:
>>
>> i have already tried that..
>
> Oh, I see, in 1.6 it's a bare recv() call, it doesn't cooperate with
> the multi-threading.  Hmm.  Not sure if it's easy to fix that, it
> works in 1.8 because pthreads takes care of all blocking.

oh... but it was cvs guile. I also tried with 1.8, still no luck,
though. :( 

And you also don't have the slib problem? I guess it might be some
platform related issue then. (It's debian on an ibook here.)

> As a workaround in 1.6 I think you can stick in a select call
>
>       (select (list sock) '() '())
>
> just before the recv!, to wait for sock to have data ready to read.
> (When select blocks it cooperates with the multi-threading, letting
> other threads run.)

This workaround works nice. Thank you so much!  i can continue my little
program again. :)

-- 
William




reply via email to

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