]> xenbits.xensource.com Git - libvirt.git/commitdiff
Prevent initializing ebtables if disabled in qemu.conf
authorRyota Ozaki <ozaki.ryota@gmail.com>
Wed, 11 Nov 2009 11:59:54 +0000 (12:59 +0100)
committerDaniel Veillard <veillard@redhat.com>
Wed, 11 Nov 2009 11:59:54 +0000 (12:59 +0100)
* src/qemu/qemu_conf.c: don't initialize ebtables if
  disabled

src/qemu/qemu_conf.c

index 28567b241cb9b1cfecfcec3099aeed2c50db4ddf..5f492ddb9bf1d018b0f38d2b5ad2a6ff16fe46c8 100644 (file)
@@ -322,7 +322,7 @@ int qemudLoadDriverConfig(struct qemud_driver *driver,
 
     p = virConfGetValue (conf, "mac_filter");
     CHECK_TYPE ("mac_filter", VIR_CONF_LONG);
-    if (p) {
+    if (p && p->l) {
         driver->macFilter = p->l;
         if (!(driver->ebtables = ebtablesContextNew("qemu"))) {
             driver->macFilter = 0;