mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-09 19:06:15 +01:00
gdbus: Fix runtime warning with debug enabled
With debug enabled, g_dbus_connection_call_done() will throw a g_warning() if the call failed (on purpose or not) while trying to the serial of a non-existant reply. (/builds/GNOME/glib/_build/gio/tests/gdbus-connection:26921): GLib-GIO-CRITICAL **: 10:10:16.311: g_dbus_message_get_reply_serial: assertion 'G_IS_DBUS_MESSAGE (message)' failed
This commit is contained in:
parent
8fd71dccc5
commit
145dc5a49e
@ -5726,17 +5726,19 @@ g_dbus_connection_call_done (GObject *source,
|
||||
_g_dbus_debug_print_lock ();
|
||||
g_print ("========================================================================\n"
|
||||
"GDBus-debug:Call:\n"
|
||||
" <<<< ASYNC COMPLETE %s() (serial %d)\n"
|
||||
" ",
|
||||
state->method_name,
|
||||
g_dbus_message_get_reply_serial (reply));
|
||||
" <<<< ASYNC COMPLETE %s()",
|
||||
state->method_name);
|
||||
|
||||
if (reply != NULL)
|
||||
{
|
||||
g_print ("SUCCESS\n");
|
||||
g_print (" (serial %d)\n"
|
||||
" SUCCESS\n",
|
||||
g_dbus_message_get_reply_serial (reply));
|
||||
}
|
||||
else
|
||||
{
|
||||
g_print ("FAILED: %s\n",
|
||||
g_print ("\n"
|
||||
" FAILED: %s\n",
|
||||
error->message);
|
||||
}
|
||||
_g_dbus_debug_print_unlock ();
|
||||
|
Loading…
Reference in New Issue
Block a user