Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re^2: Check for "No child processes" internationally

by Anonymous Monk
on May 09, 2013 at 06:58 UTC ( [id://1032731]=note: print w/replies, xml ) Need Help??


in reply to Re: Check for "No child processes" internationally
in thread Check for "No child processes" internationally

# A variation on Errno's POD example: use Errno qw( ECHILD );

:) Unless you need the number/constant, you don't need to import from Errno

Also, you don't need to actually use Errno;, using %! in your code will load Errno for you

Replies are listed 'Best First'.
Re^3: Check for "No child processes" internationally
by davido (Cardinal) on May 09, 2013 at 07:02 UTC

    Thanks for the tips. :)

    The updated code (removed the 'use', and of course the import):

    # A variation on Errno's POD example: # ........ Do your stuff ........ if ( not close $something ) { if( not $!{ECHILD} ) { die "Houston, we have a problem: $!"; } else { # Silence is golden; ECHILD is silent. } }

    Dave

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (7)
As of 2024-03-28 20:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found