From: "Mark Henry" <[EMAIL PROTECTED]> > I want to be able to restart a script under certain conditions, and I was > thinking of how I would do this using exec in ksh. > > exec as I understand it is 'replace the current process with the specified > program', where in perl it seems to be 'run the specified program but dont > wait for it to finish or care what it does', i.e. it doesnt appear to > replace the currently running prog. > > Am I close? > > fork/exec seems to be a tad different in perl - though probably I'm just not > understanding.
Depends on the OS. Under Unix Perl's exec() is the exec you are looking for. Under Windows it's implemented some other way. With functionality as similar to the Unix implementation as possible. Which doesn't say that much. Basicaly it just starts the other program and exits. So the process ID will be different and I'm not entirely sure about the filehandles. Jenda ===== [EMAIL PROTECTED] === http://Jenda.Krynicky.cz ===== When it comes to wine, women and song, wizards are allowed to get drunk and croon as much as they like. -- Terry Pratchett in Sourcery -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/