cryptospore / rpms / qemu-kvm

Forked from rpms/qemu-kvm 2 years ago
Clone
218e99
From 7805c18f11162994f870271080ab0848759a6d07 Mon Sep 17 00:00:00 2001
218e99
From: Paolo Bonzini <pbonzini@redhat.com>
218e99
Date: Fri, 18 Oct 2013 08:14:48 +0200
218e99
Subject: [PATCH 23/81] qemu-img: fix invalid JSON
218e99
218e99
RH-Author: Paolo Bonzini <pbonzini@redhat.com>
218e99
Message-id: <1382084091-16636-24-git-send-email-pbonzini@redhat.com>
218e99
Patchwork-id: 55006
218e99
O-Subject: [RHEL 7.0 qemu-kvm PATCH 23/26] qemu-img: fix invalid JSON
218e99
Bugzilla: 989646
218e99
RH-Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
218e99
RH-Acked-by: Max Reitz <mreitz@redhat.com>
218e99
RH-Acked-by: Kevin Wolf <kwolf@redhat.com>
218e99
218e99
Single quotes for JSON are a QMP-ism, use real JSON in
218e99
qemu-img output.
218e99
218e99
Reported-by: Kevin Wolf <kwolf@redhat.com>
218e99
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
218e99
(cherry picked from commit c745bfb4300206280ce6156b4bafe765f610057c)
218e99
---
218e99
 qemu-img.c | 2 +-
218e99
 1 file changed, 1 insertion(+), 1 deletion(-)
218e99
218e99
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
218e99
---
218e99
 qemu-img.c |    2 +-
218e99
 1 files changed, 1 insertions(+), 1 deletions(-)
218e99
218e99
diff --git a/qemu-img.c b/qemu-img.c
218e99
index e58c052..3a59bf0 100644
218e99
--- a/qemu-img.c
218e99
+++ b/qemu-img.c
218e99
@@ -1960,7 +1960,7 @@ static void dump_map_entry(OutputFormat output_format, MapEntry *e,
218e99
                (e->flags & BDRV_BLOCK_ZERO) ? "true" : "false",
218e99
                (e->flags & BDRV_BLOCK_DATA) ? "true" : "false");
218e99
         if (e->flags & BDRV_BLOCK_OFFSET_VALID) {
218e99
-            printf(", 'offset': %"PRId64"", e->offset);
218e99
+            printf(", \"offset\": %"PRId64"", e->offset);
218e99
         }
218e99
         putchar('}');
218e99
 
218e99
-- 
218e99
1.7.1
218e99