From: Michael Catanzaro <mcatanzaro@redhat.com>
Date: Wed, 30 Apr 2025 12:07:01 -0500
Subject: test-utils: flush stdout after printing

test_printf() would be more useful if it were to actually guarantee
that everything has printed; otherwise, it cannot be used to determine
how far we've made it in a test before a hang.

Origin: upstream, 3.7.0, commit:3eec3d8b9b5d8ac1e202d02c715663a440e6a508
---
 tests/test-utils.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tests/test-utils.c b/tests/test-utils.c
index 37cd00b..62f0b83 100644
--- a/tests/test-utils.c
+++ b/tests/test-utils.c
@@ -143,6 +143,8 @@ debug_printf (int level, const char *format, ...)
 	va_start (args, format);
 	g_vprintf (format, args);
 	va_end (args);
+
+	fflush (stdout);
 }
 
 gboolean
