From 9a875c6c5dd1e7cb0dad56d593a428d570ea5111 Mon Sep 17 00:00:00 2001 From: luozhengzheng Date: Sat, 15 Oct 2016 00:40:08 +0800 Subject: [PATCH] Fix coverity defects: CID 150921, 150927 CID 150921: Unchecked return value (CHECKED_RETURN) CID 150927 : Unchecked return value (CHECKED_RETURN) Reviewed-by: Brian Behlendorf Signed-off-by: luozhengzheng Closes #5267 --- lib/libspl/getexecname.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/libspl/getexecname.c b/lib/libspl/getexecname.c index 478351ce7..c21a110ad 100644 --- a/lib/libspl/getexecname.c +++ b/lib/libspl/getexecname.c @@ -38,7 +38,7 @@ getexecname(void) char *ptr = NULL; ssize_t rc; - pthread_mutex_lock(&mtx); + (void) pthread_mutex_lock(&mtx); if (strlen(execname) == 0) { rc = readlink("/proc/self/exe", @@ -53,6 +53,6 @@ getexecname(void) ptr = execname; } - pthread_mutex_unlock(&mtx); + (void) pthread_mutex_unlock(&mtx); return (ptr); }