Gurus,
In a code segment, I have the code below
strcat(cmdstring, "/export/home/user9/scripts/trans");
// trans is an executable script
status = system(cmdstring);
if (status = -1) {
sprintf(msg, "System() call failed\n");
}
else
{
sprintf(msg, "System() call succeeded\n");
}
My debugging message showed "System() call succeeded". That means the script "trans" was called and executed. However, the "trans" script did not output any debug message. Once "trans" is executed, it should write a "transaction.log" file to the directory /export/home/user9/log. But I got nothing by calling "system()". Is there a way I can check further the status for calling "system()"?
Thanks so much.
Fox12
In a code segment, I have the code below
strcat(cmdstring, "/export/home/user9/scripts/trans");
// trans is an executable script
status = system(cmdstring);
if (status = -1) {
sprintf(msg, "System() call failed\n");
}
else
{
sprintf(msg, "System() call succeeded\n");
}
My debugging message showed "System() call succeeded". That means the script "trans" was called and executed. However, the "trans" script did not output any debug message. Once "trans" is executed, it should write a "transaction.log" file to the directory /export/home/user9/log. But I got nothing by calling "system()". Is there a way I can check further the status for calling "system()"?
Thanks so much.
Fox12