--- a/src/rpc/virnetdaemon.c
+++ b/src/rpc/virnetdaemon.c
@@ -515,13 +515,9 @@ virNetDaemonCallInhibit(virNetDaemonPtr
&pendingReply,
25 * 1000) &&
pendingReply) {
- if (dbus_pending_call_get_completed(pendingReply)) {
- virNetDaemonGotInhibitReply(pendingReply, dmn);
- } else {
- dbus_pending_call_set_notify(pendingReply,
- virNetDaemonGotInhibitReply,
- dmn, NULL);
- }
+ dbus_pending_call_set_notify(pendingReply,
+ virNetDaemonGotInhibitReply,
+ dmn, NULL);
dmn->autoShutdownCallingInhibit = true;
}
virDBusMessageUnref(message);