Code

Merge branch 'collectd-5.5'
[collectd.git] / src / exec.c
index 85f6cb8038a21b12a0db63668164b3585d885577..6d5908c05faedc03583bcad0d4434c3dc6ba7abb 100644 (file)
@@ -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);