From: Simon McVittie Date: Thu, 21 Jul 2016 09:55:59 +0000 (+0100) Subject: internals: remove newline, pid from assertion failures X-Git-Tag: dbus-1.11.6~18 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b8abdc52afcc36dbd6dfbee3a5532048f88097bf;p=thirdparty%2Fdbus.git internals: remove newline, pid from assertion failures _dbus_warn() now calls _dbus_logv() which always logs the pid and prints a newline anyway. Signed-off-by: Simon McVittie Reviewed-by: Ralf Habacker Bug: https://bugs.freedesktop.org/show_bug.cgi?id=97009 --- diff --git a/dbus/dbus-internals.c b/dbus/dbus-internals.c index ae6b9a135..17bb39c4e 100644 --- a/dbus/dbus-internals.c +++ b/dbus/dbus-internals.c @@ -972,8 +972,8 @@ _dbus_real_assert (dbus_bool_t condition, { if (_DBUS_UNLIKELY (!condition)) { - _dbus_warn ("%lu: assertion failed \"%s\" file \"%s\" line %d function %s\n", - _dbus_pid_for_log (), condition_text, file, line, func); + _dbus_warn ("assertion failed \"%s\" file \"%s\" line %d function %s", + condition_text, file, line, func); _dbus_abort (); } } @@ -993,8 +993,8 @@ _dbus_real_assert_not_reached (const char *explanation, const char *file, int line) { - _dbus_warn ("File \"%s\" line %d process %lu should not have been reached: %s\n", - file, line, _dbus_pid_for_log (), explanation); + _dbus_warn ("File \"%s\" line %d should not have been reached: %s", + file, line, explanation); _dbus_abort (); } #endif /* DBUS_DISABLE_ASSERT */