Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic

Re: Problem timing out XML::LibXML parsing

by gwadej (Chaplain)
on Feb 03, 2009 at 20:26 UTC ( #741118=note: print w/replies, xml ) Need Help??

in reply to Problem timing out XML::LibXML parsing

I'm not completely sure, but isn't there something about signals in Perl having been changed so that they are only returned when you are somewhere safe in Perl. Deferred_Signals_(Safe_Signals)

There's a environment variable (PERL_SIGNALS) you can set to unsafe that disables this behavior. That might allow you to test if alarm is being affected by this feature.

G. Wade

Replies are listed 'Best First'.
Re^2: Problem timing out XML::LibXML parsing
by hobbs (Monk) on Feb 04, 2009 at 00:54 UTC
    The other thing that you can do, which is also documented in perlipc, is to use POSIX::sigaction() to set your handler, which has the advantage of only invoking the "unsafe" behavior for that particular SIGALRM and not for any signal your app might catch, ever. You decide whether that sounds worth your time or not :)

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://741118]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (3)
As of 2022-09-29 21:12 GMT
Find Nodes?
    Voting Booth?
    I prefer my indexes to start at:

    Results (125 votes). Check out past polls.