[libvirt] Correct a check for capacity arg of storageVolumeResize()

Zeeshan Ali (Khattak) zeeshanak at gnome.org
Fri Feb 24 03:00:51 UTC 2012


From: "Zeeshan Ali (Khattak)" <zeeshanak at gnome.org>

---
 src/storage/storage_driver.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/storage/storage_driver.c b/src/storage/storage_driver.c
index df0e291..641944d 100644
--- a/src/storage/storage_driver.c
+++ b/src/storage/storage_driver.c
@@ -1758,7 +1758,7 @@ storageVolumeResize(virStorageVolPtr obj,
         goto out;
     }
 
-    if (abs_capacity > vol->allocation + pool->def->available) {
+    if (abs_capacity > vol->capacity + pool->def->available) {
         virStorageReportError(VIR_ERR_INVALID_ARG,
                               _("Not enough space left on storage pool"));
         goto out;
-- 
1.7.7.6




More information about the libvir-list mailing list