Arthur,
Please excuse my ignorance of the Perl internals but I was wondering if you could
explain exactly what the issue with ithreads and signals is.
> > In other words something similar to this:
> >
> >
> > eval {
> > $| = 1;
> > local $SIG{ALRM} = sub { die 'timeout!' };
> > alarm($timeoutsec);
> > # DO SOMETHING HERE
> > $status = do_something();
> > alarm(0);
> > };
> > if(!$status) {
> > # Timed out
> > # HANDLE THE TIMEOUT PROPERLY
> > }
On the two platforms I'm most familiar with, Linux and Solaris, this would actually
work as long as it was running in the "original" thread. After some testing to seems
that all signals are delivered to the "original" thread regardless of where it was
generated. I know that with pthreads signals should only be delivered to thread that
requested the interrupt. Are the ithread issues caused by the new "safe" signal
facility?
Cheers,
-J