X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fexec.c;h=cdaf79a0b04e741aee314aafb90921ff1fe0ef9b;hb=cd5602386cf810ade2750bf026e5fe340765ce05;hp=85f6cb8038a21b12a0db63668164b3585d885577;hpb=12f249b209d7fa31e3a9d53315e47a2342463e0f;p=collectd.git diff --git a/src/exec.c b/src/exec.c index 85f6cb80..cdaf79a0 100644 --- a/src/exec.c +++ b/src/exec.c @@ -38,8 +38,6 @@ #include #include -#include - #define PL_NORMAL 0x01 #define PL_NOTIF_ACTION 0x02 @@ -742,8 +740,7 @@ static void *exec_notification_one (void *arg) /* {{{ */ char errbuf[1024]; ERROR ("exec plugin: fdopen (%i) failed: %s", fd, sstrerror (errno, errbuf, sizeof (errbuf))); - kill (pl->pid, SIGTERM); - pl->pid = 0; + kill (pid, SIGTERM); close (fd); sfree (arg); pthread_exit ((void *) 1);