in reply to Re^2: Signal handling in embedded Perl ?
in thread Signal handling in embedded Perl ?
But when embedding perl inside another program/platform, you'd be doing the same thing at the C level, and calling the POSIX sigaction() function (or its equivalent).
(At least I think you would - I'd be very suprised if the existing value of $SIG{FOO} you stored in $original was a callable C function. But then, I've been surprised before).
And being in C not perl, you wouldn't have the convenience of having a nice closure to capture your state, so you'd need to have a data structure (perhaps a global array indexed by signal number).
|
|---|