Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^4: Question regarding handling exceptions in subroutine

by karlgoethebier (Abbot)
on May 12, 2013 at 12:23 UTC ( [id://1033193]=note: print w/replies, xml ) Need Help??


in reply to Re^3: Question regarding handling exceptions in subroutine
in thread Question regarding handling exceptions in subroutine

Shouldn't it be:

my $result = qx($command); if ( $? >> 8 != 0 ) { if ($@) { die $@; } else { die qq(Something really weird happened!); } }

Regards, Karl

«The Crux of the Biscuit is the Apostrophe»

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2024-03-29 06:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found