Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Sytem Call Not Waiting

by ZlR (Chaplain)
on Feb 24, 2010 at 08:13 UTC ( #825019=note: print w/ replies, xml ) Need Help??


in reply to Sytem Call Not Waiting

From perldoc system :

system PROGRAM LIST Does exactly the same thing as exec LIST , except that a fork is done +first,

This fork is why "the system call never waits for the conversion to happen"

Perldoc also provides a way to wait for return :

system(@args) == 0 or die "system @args failed: $?"


Comment on Re: Sytem Call Not Waiting
Select or Download Code
Re^2: Sytem Call Not Waiting
by almut (Canon) on Feb 24, 2010 at 08:42 UTC
    This fork is why "the system call never waits for the conversion to happen"

    This is wrong.  system always waits for the command to complete. The only case where it won't wait is if the command itself forks another time to run in the background, because in this case the command's parent process will exit immediately.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (9)
As of 2014-07-23 06:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (133 votes), past polls