Skip to contentSkip to conversation

tests: Add proper newlines for qmp_fd_receive

PATCH New Peter Xu 1 participant 1 message Jun 5, 2019

lore
Share & tools
lore

Peter Xu

author
#0 lore raw

PATCH 1/1 tests: Add proper newlines for qmp_fd_receive

It changes QTEST_LOG=1 results a bit more lovely, from:

{"return": ... }{"execute": "query-migrate"}

{"return": ... }{"execute": "query-migrate"}

Into:

{"execute": "query-migrate"}

{"return": ... }

{"execute": "query-migrate"}

{"return": ... }

CC Thomas Huth <[email protected]>
CC Laurent Vivier <[email protected]>
CC Paolo Bonzini <[email protected]>
---
 tests/libqtest.c | 4 ++++
 1 file changed, 4 insertions(+)
tests/libqtest.c +4 -0
index 546a875913..d7301d773e 100644
@@ -532,6 +532,10 @@ QDict *qmp_fd_receive(int fd)
     }
     json_message_parser_destroy(&qmp.parser);
 
+    if (log) {
+        fprintf(stderr, "\n\n");
+    }
+
     return qmp.response;
 }
 
Signature · 1 line
2.17.1