[squeak-dev] Re: OSProcess question
Andreas Raab
andreas.raab at gmx.de
Tue Mar 11 07:29:39 UTC 2008
David T. Lewis wrote:
> Yes, you should add a delay in the loop, or use this (which adds the
> delay for you):
>
> p := OSProcess waitForCommand: 'chmod +x ', path
>
> The run state of an external OS process is updated by a separate Squeak
> process (evaluate "OSProcess accessor grimReaperProcess"), so you need
> to wait for the grimReaperProcess to react to the external process
> exit notification. On Unix, this is a SIGCHLD, which is caught by OSPP,
> which sends #signalSemaphoreWithIndex:, which wakes up the grimReaperProcess,
> which calls #primitiveReapChildProcess to clean up and obtain the child
> exit status. After all of this has happened, #isComplete will answer
> true.
Thanks, that's what I suspected. It's working great now.
Cheers,
- Andreas
More information about the Squeak-dev
mailing list
|