chicken-hackers
[Top][All Lists]
Advanced

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

Re: [Chicken-hackers] Fixing the "process" procedure to be safe against


From: Peter Bex
Subject: Re: [Chicken-hackers] Fixing the "process" procedure to be safe against execve() errors
Date: Thu, 25 Jul 2019 20:09:21 +0200
User-agent: Mutt/1.10.1 (2018-07-13)

On Thu, Jul 25, 2019 at 08:39:05PM +0300, Lassi Kortela wrote:
> I started writing a patch to fix the problems I discovered in this thread on
> chicken-users:
> <https://lists.nongnu.org/archive/html/chicken-users/2019-07/msg00041.html>.
> Is this desired?

I think so, but must confess I don't fully understand the issue.

> If it is: I got stuck on finding the right way to do poll()/select() in
> Chicken. From cursory grepping, Chicken seems to have its own thread
> scheduler which does some calls to poll. I don't understand the
> implications, so I stopped to ask for help instead of going ahead and
> wrapping Unix poll() in the obvious manner.

Very good!  You could call poll() directly, but that would block other
threads from executing.  So what you typically do is call
 ##sys#thread-block-for-i/o! on the fd followed by ##sys#thread-yield!
to actually suspend the thread.

Cheers,
Peter

Attachment: signature.asc
Description: PGP signature


reply via email to

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