[PATCH] testutils: Terminate usage string with a new line

Michal Privoznik mprivozn at redhat.com
Mon Jan 17 15:56:36 UTC 2022

If a test binary is executed with an argument then usage
information is printed out (that no arguments are accepted and
what environment variables affect execution). The string is
printed onto stderr but it is not terminated with a newline
character producing not so nice output.

Signed-off-by: Michal Privoznik <mprivozn at redhat.com>

Pushed as trivial.

 tests/testutils.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/testutils.c b/tests/testutils.c
index 322c3b9400..2b37c1965d 100644
--- a/tests/testutils.c
+++ b/tests/testutils.c
@@ -826,7 +826,7 @@ int virTestMain(int argc,
         fprintf(stderr, "Usage: %s\n", argv[0]);
         fputs("effective environment variables:\n"
               "VIR_TEST_VERBOSE set to show names of individual tests\n"
-              "VIR_TEST_DEBUG set to show information for debugging failures",
+              "VIR_TEST_DEBUG set to show information for debugging failures\n",
         return EXIT_FAILURE;

More information about the libvir-list mailing list