]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
tests: qemucapsprobe: Fix output after switching to jansson
authorPeter Krempa <pkrempa@redhat.com>
Mon, 30 Jul 2018 14:49:39 +0000 (16:49 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Wed, 1 Aug 2018 11:55:58 +0000 (13:55 +0200)
Jansson does not put a newline at the end of formatted JSON strings.
This breaks the qemucapsprobe utility as we need to keep the spacing so
that tests work. Add an explicit newline.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
tests/qemucapsprobemock.c

index 5936975505b1c9717030d19c55b71c6468ce52de..049b16273a9eb0b1b617f972b9b19d66c4f6de65 100644 (file)
@@ -76,6 +76,7 @@ qemuMonitorSend(qemuMonitorPtr mon,
         printLineSkipEmpty("\n", stdout);
 
     printLineSkipEmpty(reformatted, stdout);
+    printLineSkipEmpty("\n", stdout);
     VIR_FREE(reformatted);
 
     return realQemuMonitorSend(mon, msg);
@@ -116,6 +117,7 @@ qemuMonitorJSONIOProcessLine(qemuMonitorPtr mon,
             printLineSkipEmpty("\n", stdout);
 
         printLineSkipEmpty(json, stdout);
+        printLineSkipEmpty("\n", stdout);
     }
 
  cleanup: