I have a test.cgi program which calls a perl program by using system(). I have the code snippet like below:
print STDERR "Before Executing Cmd\n";
system($cmd);
print STDERR "Cmd complete\n";
$cmd is a .pl program which will create a three files in the specified directory.
In the log file, I can find the entry "Before Executing Cmd". And, in the specified directory, all of the three files were successfully created. However, the test.cgi return 500 Internal Server Error in the web browser. What's more weird is that "Cmd complete" was never entered into the error log file. Instead, there is an entry saying "Premature end of script header".
any Guru here can help me resolve this?
Thanks a ton in advance.
print STDERR "Before Executing Cmd\n";
system($cmd);
print STDERR "Cmd complete\n";
$cmd is a .pl program which will create a three files in the specified directory.
In the log file, I can find the entry "Before Executing Cmd". And, in the specified directory, all of the three files were successfully created. However, the test.cgi return 500 Internal Server Error in the web browser. What's more weird is that "Cmd complete" was never entered into the error log file. Instead, there is an entry saying "Premature end of script header".
any Guru here can help me resolve this?
Thanks a ton in advance.