CC: | bug-Sys-SigAction [...] rt.cpan.org |
Subject: | Re: Sys::SigAction and "safe" attribute. |
Date: | Sun, 12 Oct 2008 22:21:04 -0400 |
To: | krivenok [...] orangesystem.ru |
From: | "Lincoln A. Baxter" <lab [...] lincolnbaxter.com> |
Hi Dmitru,
See below.
On Fri, 2008-10-10 at 16:44 +0400, Dmitry V. Krivenok wrote:
Show quoted text
> Hello!
>
> Doc (http://search.cpan.org/~lbaxter/Sys-SigAction-0.10/lib/Sys/SigAction.pm) says that
> it's possible to pass "safe" attribute in set_sig_handler:
>
> my $h = set_sig_handler( 'ALRM' ,\&mysubname ,{ mask=>[ 'ALRM' ] ,safe=>1 } );
>
> However, I found (in SigAction.pm version 0.10) that this attribute is
> ignored (it is just checked in _attrs_warning subroutine).
>
> Why not to add
>
> $act->safe( $attrs->{safe} );
>
> after
>
> my $act = POSIX::SigAction->new( $handler ,$mask ,$attrs->{flags} );
>
> if perl >= 5.8.2 is used?
>
See the note at the bottom of the test, t/safe.t
I spent some time on it, and I could not come up with a way to prove it
works. I believe it doesn't, but I would be happy to be shown where my
confusion is, if that is the case. That test is an invitation to anyone
who wants it badly enough, to show me how, and I will happily release a
new version.
Lincoln
Show quoted text>
> Currently we always use unsafe signals model (despite of safe attribute).
>
>
> Thank you beforehand!
>
>