From: Marc Hartmayer <mhartmay(a)linux.vnet.ibm.com>
Report a debug message if dbus_watch_handle() returns FALSE.
dbus_watch_handle() returns FALSE if there wasn't enough memory for
reading or writing.
Signed-off-by: Marc Hartmayer <mhartmay(a)linux.ibm.com>
Reviewed-by: Bjoern Walk <bwalk(a)linux.ibm.com>
Reviewed-by: Boris Fiuczynski <fiuczy(a)linux.ibm.com>
Reviewed-by: Stefan Zimmermann <stzi(a)linux.ibm.com>
---
src/util/virdbus.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/util/virdbus.c b/src/util/virdbus.c
index 1d1e39aae728..01c67fbaf467 100644
--- a/src/util/virdbus.c
+++ b/src/util/virdbus.c
@@ -197,7 +197,8 @@ static void virDBusWatchCallback(int fdatch ATTRIBUTE_UNUSED,
if (events & VIR_EVENT_HANDLE_HANGUP)
dbus_flags |= DBUS_WATCH_HANGUP;
- (void)dbus_watch_handle(watch, dbus_flags);
+ if (dbus_watch_handle(watch, dbus_flags) == FALSE)
+ VIR_DEBUG("dbus_watch_handle() returned FALSE");
dbus_connection_ref(info->bus);
while (dbus_connection_dispatch(info->bus) == DBUS_DISPATCH_DATA_REMAINS)
--
2.17.0