Boost logo

Boost :

From: Davide Bolcioni (davide_bolcioni_at_[hidden])
Date: 2006-08-17 08:26:44


Oliver.Kowalke_at_[hidden] wrote:

> On POSIX the implementation would look like:
>
> // while loop inside of signal handling function (SIGCHLD)
> while ( true)
> {
> pid_t pid;
> int stat = 0, opts = WNOHANG | WUNTRACED;
> #ifdef WCONTINUED
> opts |= WCONTINUED;
> #endif
> pid = ::waitpid( -1, & stat, opts);
> if ( pid == 0)
> break;
> else if ( pid < 0)
> throw sys::system_error( sys::error_code( errno, sys::errno_ec)
> );

Is throwing an exception in a signal handler supported by POSIX ?

Davide Bolcioni

-- 
There is no place like /home.

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk