in reply to capturing exit status of a process

did you try system() or exec()?
### returncode 0 is success, 1+ is failure my $returnCode = system("nmblookup -r -T $client"); print "returnCode: $returnCode\n";

Replies are listed 'Best First'.
Re^2: capturing exit status of a process
by blackrose (Initiate) on Aug 09, 2004 at 14:32 UTC
    many thanks Jaap. I tried your example but i'm still getting $returnCode = 0 even though 'nmblookup' reports that it could not contact $client. Am i just reporting that 'nmblookup' itself succeeded here, not that the result of the nmblookup was a failure ?