in reply to Re^2: Fork and wait question
in thread Fork and wait question

ok, I I added what you requested. However it still will continue the program and finish. I can pull up process on my linux and it shows the two instances of the chirp_md5sum program running.
$index=0; my $inputfile="perloutput"; my $endfile=".txt "; my $smb="> "; my $outputfile="output"; my $smb2="&"; while ($index<2) { my $testpath="chirp_md5sum "; $testpath=$testpath.$inputfile.$index.$endfile.$smb.$outputfile.$in +dex.$endfile.$smb2; chomp $testpath; print ("$testpath \n"); $id=fork(); if ($id == 0) { exec($testpath) or die "unable to exec $testpath: $!\n"; } $index++; } while (wait > -1) {};