aboutsummaryrefslogtreecommitdiff
path: root/contrib/timeout_watchdog.c
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2010-06-28 10:53:00 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2010-06-28 10:53:00 +0000
commit618779d80c15219b8d9504067f286b5ac1b9b194 (patch)
tree41e3b74b553d84db093c04d16fe28662c1d04f7f /contrib/timeout_watchdog.c
parent1fbea1a160373147db6ef31f5d05d61e63296077 (diff)
downloadgnunet-618779d80c15219b8d9504067f286b5ac1b9b194.tar.gz
gnunet-618779d80c15219b8d9504067f286b5ac1b9b194.zip
Diffstat (limited to 'contrib/timeout_watchdog.c')
-rw-r--r--contrib/timeout_watchdog.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/contrib/timeout_watchdog.c b/contrib/timeout_watchdog.c
index dfeed6782..c8c339167 100644
--- a/contrib/timeout_watchdog.c
+++ b/contrib/timeout_watchdog.c
@@ -54,7 +54,6 @@ void sigchld_handler(int val)
54 54
55void sigint_handler(int val) 55void sigint_handler(int val)
56{ 56{
57 printf("Killing test process\n");
58 kill(0, val); 57 kill(0, val);
59 exit(1); 58 exit(1);
60} 59}
@@ -92,16 +91,13 @@ signal(SIGTERM, sigint_handler);
92child = fork(); 91child = fork();
93if (child==0) 92if (child==0)
94{ 93{
95 printf("Starting test process `%s'\n",argv[2],arguments);
96 setpgid(0,gpid); 94 setpgid(0,gpid);
97 execvp(argv[2],&argv[2]); 95 execvp(argv[2],&argv[2]);
98 printf("Test process `%s' could not be started\n",argv[2]);
99 exit(1); 96 exit(1);
100} 97}
101if (child > 0) 98if (child > 0)
102{ 99{
103 sleep(timeout); 100 sleep(timeout);
104 printf("Timeout, killing all test processes\n");
105 kill(0,SIGABRT); 101 kill(0,SIGABRT);
106 exit(1); 102 exit(1);
107} 103}