]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
Fix compliation of AppArmor related code
authorMatthias Bolte <matthias.bolte@googlemail.com>
Thu, 11 Feb 2010 23:09:59 +0000 (00:09 +0100)
committerMatthias Bolte <matthias.bolte@googlemail.com>
Thu, 11 Feb 2010 23:09:59 +0000 (00:09 +0100)
Broken by the latest commits to remove the virConnectPtr parameter
from internal functions.

src/security/security_apparmor.c
src/security/virt-aa-helper.c

index 23f40f8f83a0650e1a4762692a15167db1708b47..db04d5c188c4dd7de2c34eec17c95ca458966921 100644 (file)
@@ -262,7 +262,7 @@ use_apparmor(void)
     char *libvirt_daemon = NULL;
 
     if (virFileResolveLink("/proc/self/exe", &libvirt_daemon) < 0) {
-        virSecurityReportError(NULL, VIR_ERR_INTERNAL_ERROR,
+        virSecurityReportError(VIR_ERR_INTERNAL_ERROR,
                                "%s", _("could not find libvirtd"));
         return rc;
     }
@@ -295,7 +295,7 @@ AppArmorSecurityDriverProbe(void)
     }
 
     if (!virFileExists(template)) {
-        virSecurityReportError(NULL, VIR_ERR_INTERNAL_ERROR,
+        virSecurityReportError(VIR_ERR_INTERNAL_ERROR,
                                _("template \'%s\' does not exist"), template);
         goto clean;
     }
index 619c8c33200e14f71e5a4ef50f1eaafa2adb7dbc..066e18b3f3113ca04d09c14a8d3e98917ec134ac 100644 (file)
@@ -690,7 +690,7 @@ get_definition(vahControl * ctl, const char *xmlStr)
         goto exit;
     }
 
-    ctl->def = virDomainDefParseString(NULL, ctl->caps, xmlStr, 0);
+    ctl->def = virDomainDefParseString(ctl->caps, xmlStr, 0);
     if (ctl->def == NULL) {
         vah_error(ctl, 0, "could not parse XML");
         goto exit;
@@ -767,8 +767,7 @@ vah_add_file(virBufferPtr buf, const char *path, const char *perms)
 }
 
 static int
-file_iterate_cb(virConnectPtr conn ATTRIBUTE_UNUSED,
-                usbDevice *dev ATTRIBUTE_UNUSED,
+file_iterate_cb(usbDevice *dev ATTRIBUTE_UNUSED,
                 const char *file, void *opaque)
 {
     virBufferPtr buf = opaque;
@@ -844,8 +843,7 @@ get_files(vahControl * ctl)
                 if (usb == NULL)
                     continue;
 
-                rc = usbDeviceFileIterate(NULL, usb,
-                                          file_iterate_cb, &buf);
+                rc = usbDeviceFileIterate(usb, file_iterate_cb, &buf);
                 usbFreeDevice(usb);
                 if (rc != 0)
                     goto clean;