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

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

On 03/02/2010 10:04 AM, Jim Meyering wrote:
Eric Blake wrote:
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
  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,

Confirmed.  That's the only one that's ignored, and your
change makes it consistent with the others.



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