From: Simon McVittie Date: Sat, 29 Jun 2019 22:34:41 +0000 (+0100) Subject: tests: Improve diagnostics for malloc-failure tests X-Git-Tag: dbus-1.13.14~28^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4876dbb161ab82b2da005b06fdc9e5dc8e538c40;p=thirdparty%2Fdbus.git tests: Improve diagnostics for malloc-failure tests Some of these appear to hang, but making this diagnostic appear in the log reveals the truth: it's just very slow. Signed-off-by: Simon McVittie --- diff --git a/dbus/dbus-internals.c b/dbus/dbus-internals.c index 2f456edab..7420f2038 100644 --- a/dbus/dbus-internals.c +++ b/dbus/dbus-internals.c @@ -1003,9 +1003,9 @@ run_failing_each_malloc (int n_mallocs, { _dbus_set_fail_alloc_counter (n_mallocs); - _dbus_verbose ("\n===\n%s: (will fail malloc %d with %d failures)\n===\n", - description, n_mallocs, - _dbus_get_fail_alloc_failures ()); + _dbus_test_diag ("%s: will fail malloc %d and %d that follow", + description, n_mallocs, + _dbus_get_fail_alloc_failures () - 1); if (!(* func) (data, FALSE)) return FALSE;