]> xenbits.xensource.com Git - libvirt.git/commitdiff
* src/xend_internal.c: patch from Masayuki Sunou to avoid
authorDaniel Veillard <veillard@redhat.com>
Thu, 16 Aug 2007 15:38:38 +0000 (15:38 +0000)
committerDaniel Veillard <veillard@redhat.com>
Thu, 16 Aug 2007 15:38:38 +0000 (15:38 +0000)
  attach-disk/attach-interface when < Xen 3.0.4
Daniel

ChangeLog
src/xend_internal.c

index 95660481bf3d072cef1e4828bfd28cfa00d22000..f5b9aeb650022a2a26af04ecaeff6615b0203792 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Thu Aug 16 17:41:22 CEST 2007 Daniel Veillard <veillard@redhat.com>
+
+       * src/xend_internal.c: patch from Masayuki Sunou to avoid
+         attach-disk/attach-interface when < Xen 3.0.4
+
 Thu Aug 16 15:24:30 CEST 2007 Daniel Veillard <veillard@redhat.com>
 
        * src/virsh.c: vshCommandOptInt was broken as it would not
index 020e29c04834712dfe0779830a4db009a79f5d54..b77afa8d1ac601e097b17c3481b504719346e97b 100644 (file)
@@ -3091,6 +3091,13 @@ xenDaemonAttachDevice(virDomainPtr domain, char *xml)
 
     priv = (xenUnifiedPrivatePtr) domain->conn->privateData;
 
+    /*
+     * on older Xen without the inactive guests management
+     * avoid doing this on inactive guests
+     */
+    if ((domain->id < 0) && (priv->xendConfigVersion < 3))
+        return (-1);
+
     str = virDomainGetOSType(domain);
     if (strcmp(str, "linux"))
         hvm = 1;