[courtesy cc of this posting sent to cited author via email] Quoting Alan Burlison <Alan.Burlison@uk.sun.com> from ml.lang.perl.porters: :My vote is for us to revert back to setjmp, and as I indicated I may :well just disable it regardless when I integrate 5.6.1 into Solaris. The problem is to know the semantics we wish to guarantee when one does this: $SIG{ALRM} = 'IGNORE'; eval { &foo }; print "back from foo()\n"; alarm(2); select(undef, undef, undef, 4); sub TIMEOUT { die "TIMEOUT"; } sub foo { $SIG{ALRM} = 'TIMEOUT'; alarm(2); select(undef, undef, undef, 4); } For me (Linux 2.4.0, perl 5.005_03), it yields: back from foo() TIMEOUT at /home/ram/tmp/alarm line 9 Is this what is expected? I wonder where sigsetjmp() comes into play here, because what is happening shows that the signal mask is not restored, and that ALRM continues to be trapped even though we came back through a siglongjmp()? RaphaelThread Previous | Thread Next