From: Ruben Kerkhof Date: Sun, 6 Dec 2015 11:09:20 +0000 (+0100) Subject: sigrok plugin: don't pass status to strerror X-Git-Tag: collectd-5.5.1~22^2~1 X-Git-Url: https://git.octo.it/?a=commitdiff_plain;h=5997c2158f5712e4b67be142726b6a627582cc78;p=collectd.git sigrok plugin: don't pass status to strerror CID #38120 Signed-off-by: Florian Forster --- diff --git a/src/sigrok.c b/src/sigrok.c index ba3e4062..1a0536ad 100644 --- a/src/sigrok.c +++ b/src/sigrok.c @@ -357,10 +357,13 @@ static int sigrok_init(void) return -1; } - if ((status = plugin_thread_create(&sr_thread, NULL, sigrok_read_thread, - NULL)) != 0) { + status = plugin_thread_create(&sr_thread, NULL, sigrok_read_thread, + NULL); + if (status != 0) + { + char errbuf[1024]; ERROR("sigrok plugin: Failed to create thread: %s.", - strerror(status)); + sstrerror (errno, errbuf, sizeof (errbuf))); return -1; } sr_thread_running = TRUE;