aboutsummaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-05-31 16:49:27 +0000
committerChristian Grothoff <christian@grothoff.org>2012-05-31 16:49:27 +0000
commit4050d669768bdb267134a6a6cef9323bd107f79e (patch)
tree62f72a93186fb8b226c7482bc9dd6ff2533a827c /contrib
parentcbe386a2c1af69b88eba1be7240a2f19e014fd7c (diff)
downloadgnunet-4050d669768bdb267134a6a6cef9323bd107f79e.tar.gz
gnunet-4050d669768bdb267134a6a6cef9323bd107f79e.zip
-LRN: make watchdog always kill its children
Diffstat (limited to 'contrib')
-rw-r--r--contrib/timeout_watchdog_w32.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/contrib/timeout_watchdog_w32.c b/contrib/timeout_watchdog_w32.c
index 286d39a94..46a615755 100644
--- a/contrib/timeout_watchdog_w32.c
+++ b/contrib/timeout_watchdog_w32.c
@@ -173,14 +173,16 @@ main (int argc, char *argv[])
173 if (wait_result != 0) 173 if (wait_result != 0)
174 { 174 {
175 printf ("Test process exited with result %lu\n", status); 175 printf ("Test process exited with result %lu\n", status);
176 TerminateJobObject (job, status);
176 exit (status); 177 exit (status);
177 } 178 }
178 printf ("Test process exited (failed to obtain exit status)\n"); 179 printf ("Test process exited (failed to obtain exit status)\n");
180 TerminateJobObject (job, 0);
179 exit (0); 181 exit (0);
180 } 182 }
181 printf ("Child processes were killed after timeout of %u seconds\n", 183 printf ("Child processes were killed after timeout of %u seconds\n",
182 timeout); 184 timeout);
183 TerminateJobObject (job, 0); 185 TerminateJobObject (job, 1);
184 CloseHandle (proc.hProcess); 186 CloseHandle (proc.hProcess);
185 exit (1); 187 exit (1);
186} 188}