[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] [PATCH] build: silence coverity warning in node_device



All other uses of get_str_prop in this file that ignored
failure explicitly cast to void.

* src/node_device/node_device_hal.c (dev_create): Silence coverity
warning.
---
 src/node_device/node_device_hal.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/node_device/node_device_hal.c b/src/node_device/node_device_hal.c
index 6cc2864..4bf445d 100644
--- a/src/node_device/node_device_hal.c
+++ b/src/node_device/node_device_hal.c
@@ -463,7 +463,7 @@ static void dev_create(const char *udi)
         goto cleanup;

     /* Some devices don't have a path in sysfs, so ignore failure */
-    get_str_prop(ctx, udi, "linux.sysfs_path", &devicePath);
+    (void)get_str_prop(ctx, udi, "linux.sysfs_path", &devicePath);

     dev = virNodeDeviceAssignDef(&driverState->devs,
                                  def);
-- 
1.6.6.1


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]