summaryrefslogtreecommitdiffstats
path: root/runtime/stpd/librelay.c
diff options
context:
space:
mode:
authorhunt <hunt>2006-07-20 18:13:46 +0000
committerhunt <hunt>2006-07-20 18:13:46 +0000
commit91ff416b8a764b61b4f4c290f74a90fe8326cb3b (patch)
treec749bf2229300afe7493648cbac49b2ba29b06fd /runtime/stpd/librelay.c
parent8be33d656f93229877761ab7765febafbfa8a14b (diff)
downloadsystemtap-steved-91ff416b8a764b61b4f4c290f74a90fe8326cb3b.tar.gz
systemtap-steved-91ff416b8a764b61b4f4c290f74a90fe8326cb3b.tar.xz
systemtap-steved-91ff416b8a764b61b4f4c290f74a90fe8326cb3b.zip
2006-07-20 Martin Hunt <hunt@redhat.com>
* librelay.c (stp_main_loop): If module doesn't start, kill any target command.
Diffstat (limited to 'runtime/stpd/librelay.c')
-rw-r--r--runtime/stpd/librelay.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/runtime/stpd/librelay.c b/runtime/stpd/librelay.c
index c3ad77ea..6636d1eb 100644
--- a/runtime/stpd/librelay.c
+++ b/runtime/stpd/librelay.c
@@ -799,9 +799,11 @@ int stp_main_loop(void)
{
struct transport_start *t = (struct transport_start *)data;
dbug("probe_start() returned %d\n", t->pid);
- if (t->pid < 0)
+ if (t->pid < 0) {
+ if (target_cmd)
+ kill (target_pid, SIGKILL);
cleanup_and_exit(0);
- else if (target_cmd)
+ } else if (target_cmd)
kill (target_pid, SIGUSR1);
break;
}