qemu-img: fix invalid JSON
PATCH 1/1 qemu-img: fix invalid JSON
Single quotes for JSON are a QMP-ism, use real JSON in qemu-img output.
Reported-by Kevin Wolf <[email protected]>
Signed-off-by Paolo Bonzini <[email protected]>
--- qemu-img.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
qemu-img.c +1 -1
@@ -1842,7 +1842,7 @@ static void dump_map_entry(OutputFormat output_format, MapEntry *e, (e->flags &BDRV_BLOCK_ZERO ) ?"true" :"false" , (e->flags & BDRV_BLOCK_DATA) ? "true" : "false");if (e->flags &BDRV_BLOCK_OFFSET_VALID ) { -printf (", 'offset': %" PRId64"" , e->offset); +printf (", \"offset\": %" PRId64"" , e->offset); }putchar ('}' );
Signature · 1 line
1.8.3.1
Quoted 8 lines · Paolo Bonzini
Single quotes for JSON are a QMP-ism, use real JSON in qemu-img output.
Reported-by Kevin Wolf <[email protected]>Signed-off-by Paolo Bonzini <[email protected]>--- qemu-img.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by Eric Blake <[email protected]>
Quoted 15 lines
qemu-img.c +1
-1@@ -1842,7 +1842,7 @@ static void dump_map_entry(OutputFormat output_format, MapEntry *e, (e->flags &BDRV_BLOCK_ZERO ) ?"true" :"false" , (e->flags & BDRV_BLOCK_DATA) ? "true" : "false");if (e->flags &BDRV_BLOCK_OFFSET_VALID ) { -printf (", 'offset': %" PRId64"" , e->offset); +printf (", \"offset\": %" PRId64"" , e->offset); }putchar ('}' );
Signature · 2 lines
Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
Kevin Wolf
AppliedAm 11.09.2013 um 18:58 hat Eric Blake geschrieben:
Quoted 11 lines · Paolo Bonzini
Quoted 8 lines
Single quotes for JSON are a QMP-ism, use real JSON in qemu-img output.
Reported-by Kevin Wolf <[email protected]>Signed-off-by Paolo Bonzini <[email protected]>--- qemu-img.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)Reviewed-by Eric Blake <[email protected]>
Thanks, applied to the block branch.
Kevin