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