Blob Blame History Raw
diff -rup libvirt-0.6.2/src/security_selinux.c new/src/security_selinux.c
--- libvirt-0.6.2/src/security_selinux.c	2009-05-10 22:04:25.000000000 -0400
+++ new/src/security_selinux.c	2009-05-10 22:06:09.000000000 -0400
@@ -338,6 +338,9 @@ SELinuxSetSecurityImageLabel(virConnectP
 {
     const virSecurityLabelDefPtr secdef = &vm->def->seclabel;
 
+    if (!disk->src)
+        return 0;
+
     if (disk->shared) {
         return SELinuxSetFilecon(conn, disk->src, default_image_context);
     } else if (disk->readonly) {