Il 24/02/2014 15:37, Fam Zheng ha scritto:
On Mon, 02/24 14:48, Peter Lieven wrote:
Hi,

I wonder if the current output of get_block_status for compressed VMDKs is 
correct or
if we need this patch?:

diff --git a/block/vmdk.c b/block/vmdk.c
index ff6f5ee..5fa29b0 100644
--- a/block/vmdk.c
+++ b/block/vmdk.c
@@ -1146,7 +1146,7 @@ static int64_t coroutine_fn 
vmdk_co_get_block_status(BlockDriverState *bs,
         break;
     case VMDK_OK:
         ret = BDRV_BLOCK_DATA;
-        if (extent->file == bs->file) {
+        if (extent->file == bs->file && !extent->compressed) {
             ret |= BDRV_BLOCK_OFFSET_VALID | offset;
         }


Yes, I think you are right. The output shouldn't contain offset for compressed
extents.

Ack.

Paolo



Reply via email to