mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-01-12 15:36:17 +01:00
GDBusWorker: debug on read errors if transport debugging is enabled
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=662100 Bug-NB: NB#287088 Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk> Reviewed-by: Colin Walters <walters@verbum.org>
This commit is contained in:
parent
fc21c6ced0
commit
214d249f40
@ -647,6 +647,19 @@ _g_dbus_worker_do_read_cb (GInputStream *input_stream,
|
||||
|
||||
if (bytes_read == -1)
|
||||
{
|
||||
if (G_UNLIKELY (_g_dbus_debug_transport ()))
|
||||
{
|
||||
_g_dbus_debug_print_lock ();
|
||||
g_print ("========================================================================\n"
|
||||
"GDBus-debug:Transport:\n"
|
||||
" ---- READ ERROR on stream of type %s:\n"
|
||||
" ---- %s %d: %s\n",
|
||||
g_type_name (G_TYPE_FROM_INSTANCE (g_io_stream_get_input_stream (worker->stream))),
|
||||
g_quark_to_string (error->domain), error->code,
|
||||
error->message);
|
||||
_g_dbus_debug_print_unlock ();
|
||||
}
|
||||
|
||||
/* Every async read that uses this callback uses worker->cancellable
|
||||
* as its GCancellable. worker->cancellable gets cancelled if and only
|
||||
* if the GDBusConnection tells us to close (either via
|
||||
|
Loading…
Reference in New Issue
Block a user