Bug #4708
bail if system() or popen()ed programs were killed.
Description
bail if system() or popen()ed programs were killed:
As mentioned, system() ignores SIGINT and SIGQUIT. This may make programs that call it from a loop uninterruptible, unless they take care themselves to check the exit status of the child. E.g.
while (something) {
int ret = system("foo");
if (WIFSIGNALED &&
(WTERMSIG SIGINT || WTERMSIG(ret) SIGQUIT))
break;
}
History
#1 Updated by Marc Mengel about 7 years ago
- % Done changed from 0 to 90
- Estimated time set to 2.00 h
I went through all the system() and popen() calls and made sure we were checking the return code for
WIFSIGNALED, and if we were, I throw an exception. Rerunning tests now..
commit: 37f5916
#2 Updated by Marc Mengel about 7 years ago
- Status changed from New to Resolved
- % Done changed from 90 to 100
#3 Updated by Marc Mengel about 6 years ago
- Status changed from Resolved to Closed