]> xenbits.xensource.com Git - libvirt.git/commit
build: Don't use code with dbus_message_unref when built without dbus
authorMartin Kletzander <mkletzan@redhat.com>
Mon, 14 Apr 2014 08:50:42 +0000 (10:50 +0200)
committerMartin Kletzander <mkletzan@redhat.com>
Mon, 14 Apr 2014 16:19:36 +0000 (18:19 +0200)
commit489769811080c624a4622e29698b7e348b979bc7
tree263e59573026ce2fac3b741b9c19c077e24f23bb
parent110c0db88c27eb44f6cceb02873a32f559559ed2
build: Don't use code with dbus_message_unref when built without dbus

In order to do that, virNodeSuspendSupportsTargetPMUtils() and
virSystemdPMSupportTarget() are created even when pm-utils and dbus
are compiled out, respectively, but in that case returning -2 meaning
"unavailable" (this return code was already used for unavailability
before).  Error is reported in virNodeSuspendSupportsTarget() only if
both functions returned -2, otherwise the error (or success) is properly
propagated up the stack.

Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
src/util/virnodesuspend.c
src/util/virsystemd.c