]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
fix a miscalculation of command line size for vgcreate
authorDaniel Veillard <veillard@redhat.com>
Thu, 4 Sep 2008 13:13:32 +0000 (13:13 +0000)
committerDaniel Veillard <veillard@redhat.com>
Thu, 4 Sep 2008 13:13:32 +0000 (13:13 +0000)
* src/storage_backend_logical.c: fix a miscalculation of command line
  size for vgcreate, patch from Jim Fehlig
Daniel

ChangeLog
src/storage_backend_logical.c

index a82bcef659a4e4ad699e4ad2c18d63f5c4369855..fdcdafe8e0fcb1911dd42909cab18f7f2fd8f910 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Thu Sep  4 15:05:34 CEST 2008 Daniel Veillard <veillard@redhat.com>
+
+       * src/storage_backend_logical.c: fix a miscalculation of command line
+         size for vgcreate, patch from Jim Fehlig
+
 Thu Sep  4 11:43:20 BST 2008 Daniel P. Berrange <berrange@redhat.com>
 
        Augeas config file support
index d182b5e36dd131f147f3b380f593c9dc2958dbc5..744848d26b827924572eb624389328f69da7bdde 100644 (file)
@@ -351,7 +351,7 @@ virStorageBackendLogicalBuildPool(virConnectPtr conn,
     memset(zeros, 0, sizeof(zeros));
 
     /* XXX multiple pvs */
-    if (VIR_ALLOC_N(vgargv, 1) < 0) {
+    if (VIR_ALLOC_N(vgargv, 3 + pool->def->source.ndevice) < 0) {
         virStorageReportError(conn, VIR_ERR_NO_MEMORY, "%s", _("command line"));
         return -1;
     }