Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

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

by Anonymous Monk
on May 09, 2013 at 06:58 UTC ( #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


Comment on Re^2: Check for "No child processes" internationally
Download Code
Replies are listed 'Best First'.
Re^3: Check for "No child processes" internationally
by davido (Archbishop) 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
Node Status?
node history
Node Type: note [id://1032731]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (11)
As of 2015-07-28 22:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (259 votes), past polls