[libvirt] [PATCH 1/3] Coverity: Resolve a CHECKED_RETURN message

John Ferlan jferlan at redhat.com
Tue Mar 25 18:00:08 UTC 2014


Recent changes to the module seemed to have caused Coverity to find a new
issue regarding the failure to check the return from a sendmsg. The code
doesn't seem to care about the return status, so just added an ignore_value
to keep Coverity quiet.

Signed-off-by: John Ferlan <jferlan at redhat.com>
---
 src/util/virlog.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util/virlog.c b/src/util/virlog.c
index d0afd10..056950e 100644
--- a/src/util/virlog.c
+++ b/src/util/virlog.c
@@ -1003,7 +1003,7 @@ virLogOutputToJournald(virLogSourcePtr source,
 
     mh.msg_controllen = cmsg->cmsg_len;
 
-    sendmsg(journalfd, &mh, MSG_NOSIGNAL);
+    ignore_value(sendmsg(journalfd, &mh, MSG_NOSIGNAL));
 
  cleanup:
     VIR_LOG_CLOSE(buffd);
-- 
1.8.5.3




More information about the libvir-list mailing list