X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fexec.c;h=6d5908c05faedc03583bcad0d4434c3dc6ba7abb;hb=c6557cb8950f50a41a1decfb34439b060e2fd371;hp=85f6cb8038a21b12a0db63668164b3585d885577;hpb=12f249b209d7fa31e3a9d53315e47a2342463e0f;p=collectd.git diff --git a/src/exec.c b/src/exec.c index 85f6cb80..6d5908c0 100644 --- a/src/exec.c +++ b/src/exec.c @@ -742,8 +742,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);