qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] qemu-img: fix invalid JSON
@ 2013-09-11 16:47 Paolo Bonzini
  2013-09-11 16:58 ` Eric Blake
  0 siblings, 1 reply; 3+ messages in thread
From: Paolo Bonzini @ 2013-09-11 16:47 UTC (permalink / raw)
  To: qemu-devel; +Cc: kwolf, stefanha

Single quotes for JSON are a QMP-ism, use real JSON in
qemu-img output.

Reported-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 qemu-img.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/qemu-img.c b/qemu-img.c
index 3e5e388..626365d 100644
--- a/qemu-img.c
+++ b/qemu-img.c
@@ -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('}');
 
-- 
1.8.3.1

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] [PATCH] qemu-img: fix invalid JSON
  2013-09-11 16:47 [Qemu-devel] [PATCH] qemu-img: fix invalid JSON Paolo Bonzini
@ 2013-09-11 16:58 ` Eric Blake
  2013-09-12 11:50   ` Kevin Wolf
  0 siblings, 1 reply; 3+ messages in thread
From: Eric Blake @ 2013-09-11 16:58 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: kwolf, qemu-devel, stefanha

[-- Attachment #1: Type: text/plain, Size: 1039 bytes --]

On 09/11/2013 10:47 AM, Paolo Bonzini wrote:
> Single quotes for JSON are a QMP-ism, use real JSON in
> qemu-img output.
> 
> Reported-by: Kevin Wolf <kwolf@redhat.com>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> ---
>  qemu-img.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Eric Blake <eblake@redhat.com>

> 
> diff --git a/qemu-img.c b/qemu-img.c
> index 3e5e388..626365d 100644
> --- a/qemu-img.c
> +++ b/qemu-img.c
> @@ -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('}');
>  
> 

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 621 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] [PATCH] qemu-img: fix invalid JSON
  2013-09-11 16:58 ` Eric Blake
@ 2013-09-12 11:50   ` Kevin Wolf
  0 siblings, 0 replies; 3+ messages in thread
From: Kevin Wolf @ 2013-09-12 11:50 UTC (permalink / raw)
  To: Eric Blake; +Cc: Paolo Bonzini, qemu-devel, stefanha

Am 11.09.2013 um 18:58 hat Eric Blake geschrieben:
> On 09/11/2013 10:47 AM, Paolo Bonzini wrote:
> > Single quotes for JSON are a QMP-ism, use real JSON in
> > qemu-img output.
> > 
> > Reported-by: Kevin Wolf <kwolf@redhat.com>
> > Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
> > ---
> >  qemu-img.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> Reviewed-by: Eric Blake <eblake@redhat.com>

Thanks, applied to the block branch.

Kevin

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-09-12 11:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-11 16:47 [Qemu-devel] [PATCH] qemu-img: fix invalid JSON Paolo Bonzini
2013-09-11 16:58 ` Eric Blake
2013-09-12 11:50   ` Kevin Wolf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).