diff --git a/src/storage/storage_backend_disk.c b/src/storage/storage_backend_disk.c index 4dc63d753e1e06ed6b305cad2466ac1f1d72f144..c4bd6fe2c501d089b75322c3e1f927d473f7512c 100644 --- a/src/storage/storage_backend_disk.c +++ b/src/storage/storage_backend_disk.c @@ -309,7 +309,12 @@ virStorageBackendDiskReadPartitions(virStoragePoolObjPtr pool, pool->def->source.devices[0].path, NULL); - pool->def->allocation = pool->def->capacity = pool->def->available = 0; + /* If a volume is passed, virStorageBackendDiskMakeVol only updates the + * pool allocation for that single volume. + */ + if (!vol) + pool->def->allocation = 0; + pool->def->capacity = pool->def->available = 0; ret = virCommandRunNul(cmd, 6,