[libvirt] [PATCH 2/2] vbox: Resolve Coverity CHECKED_RETURN

John Ferlan jferlan at redhat.com
Thu Nov 19 14:06:05 UTC 2015


Other callers check return from virDomainGraphicsListenSetAddress, but
vbox doesn't in it's vboxDumpDisplay. Follow other instances within vbox
to just ignore the return value in the vboxDump* functions.

Signed-off-by: John Ferlan <jferlan at redhat.com>
---
 src/vbox/vbox_common.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/vbox/vbox_common.c b/src/vbox/vbox_common.c
index 3e6ed7a..4576a07 100644
--- a/src/vbox/vbox_common.c
+++ b/src/vbox/vbox_common.c
@@ -3408,8 +3408,9 @@ vboxDumpDisplay(virDomainDefPtr def, vboxGlobalData *data, IMachine *machine)
                 if (netAddressUtf16) {
                     VBOX_UTF16_TO_UTF8(netAddressUtf16, &netAddressUtf8);
                     if (STRNEQ(netAddressUtf8, ""))
-                        virDomainGraphicsListenSetAddress(def->graphics[def->ngraphics], 0,
-                                                          netAddressUtf8, -1, true);
+                        ignore_value(virDomainGraphicsListenSetAddress(
+                                     def->graphics[def->ngraphics], 0,
+                                     netAddressUtf8, -1, true));
                     VBOX_UTF16_FREE(netAddressUtf16);
                     VBOX_UTF8_FREE(netAddressUtf8);
                 }
-- 
2.5.0




More information about the libvir-list mailing list