write_tsdb plugin: Unlock mutex before destroying it.
authorFlorian Forster <octo@collectd.org>
Mon, 20 Nov 2017 10:19:52 +0000 (11:19 +0100)
committerFlorian Forster <octo@collectd.org>
Mon, 20 Nov 2017 10:19:52 +0000 (11:19 +0100)
CID: 179224

src/write_tsdb.c

index 0c87c47..9cb3c97 100644 (file)
@@ -219,6 +219,7 @@ static void wt_callback_free(void *data) {
   sfree(cb->service);
   sfree(cb->host_tags);
 
+  pthread_mutex_unlock(&cb->send_lock);
   pthread_mutex_destroy(&cb->send_lock);
 
   sfree(cb);