Perl exec vs. system
December 04, 2009 05:29:11 Last update: December 04, 2009 05:29:11
From Perldoc:
The
Since it's a common mistake to use
The
exec function executes a system command and never returns - use system instead of exec if you want it to return. It fails and returns false only if the command does not exist and it is executed directly instead of via your system's command shell.
Since it's a common mistake to use
exec instead of system, Perl warns you (if -w is set - but you always do that) if there is a following statement which isn't die, warn, or exit .Easy email testing with http://www.ximailstop.com