[6.0] e4a727803 flexelint 534: Ignoring return value of function

Dridi Boukelmoune dridi.boukelmoune at gmail.com
Thu Aug 16 08:52:35 UTC 2018


commit e4a727803c67849c3f2a6a4debd9353baad505f1
Author: Nils Goroll <nils.goroll at uplex.de>
Date:   Thu Apr 5 11:43:39 2018 +0200

    flexelint 534: Ignoring return value of function

diff --git a/bin/varnishd/cache/cache_main.c b/bin/varnishd/cache/cache_main.c
index e2381a475..ad7e31249 100644
--- a/bin/varnishd/cache/cache_main.c
+++ b/bin/varnishd/cache/cache_main.c
@@ -102,14 +102,14 @@ THR_SetName(const char *name)
 
 	AZ(pthread_setspecific(name_key, name));
 #if defined(HAVE_PTHREAD_SET_NAME_NP)
-	pthread_set_name_np(pthread_self(), name);
+	(void)pthread_set_name_np(pthread_self(), name);
 #elif defined(HAVE_PTHREAD_SETNAME_NP)
 #if defined(__APPLE__)
-	pthread_setname_np(name);
+	(void)pthread_setname_np(name);
 #elif defined(__NetBSD__)
-	pthread_setname_np(pthread_self(), "%s", (char *)(uintptr_t)name);
+	(void)pthread_setname_np(pthread_self(), "%s", (char *)(uintptr_t)name);
 #else
-	pthread_setname_np(pthread_self(), name);
+	(void)pthread_setname_np(pthread_self(), name);
 #endif
 #endif
 }


More information about the varnish-commit mailing list