diff options
author | 2012-08-28 15:19:31 +0200 | |
---|---|---|
committer | 2012-08-29 12:00:23 +0800 | |
commit | f33dfffc41751c514c3c2a2e7e32258de6275198 (patch) | |
tree | a4bb72c61276401d53250fe82faf9e231c43b743 /src | |
parent | Don't require gawk for a simple print expression (diff) | |
download | libvirt-f33dfffc41751c514c3c2a2e7e32258de6275198.tar.gz libvirt-f33dfffc41751c514c3c2a2e7e32258de6275198.tar.bz2 libvirt-f33dfffc41751c514c3c2a2e7e32258de6275198.zip |
nwfilter: Don't try to acquire DBus context when DBus is disabled
To silence error if DBus support is not compiled in.
Diffstat (limited to 'src')
-rw-r--r-- | src/nwfilter/nwfilter_driver.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/nwfilter/nwfilter_driver.c b/src/nwfilter/nwfilter_driver.c index ae099606f..a30026ee7 100644 --- a/src/nwfilter/nwfilter_driver.c +++ b/src/nwfilter/nwfilter_driver.c @@ -168,7 +168,11 @@ static int nwfilterDriverStartup(int privileged) { char *base = NULL; - DBusConnection *sysbus = virDBusGetSystemBus(); + DBusConnection *sysbus = NULL; + +#if HAVE_DBUS + sysbus = virDBusGetSystemBus(); +#endif /* HAVE_DBUS */ if (VIR_ALLOC(driverState) < 0) goto alloc_err_exit; |