mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-08 09:40:10 +00:00
Merge branch 'wip/smcv/cups-dbus-error' into 'main'
printing: Treat any G_DBUS_ERROR contacting Avahi as non-problematic See merge request GNOME/gtk!7835
This commit is contained in:
commit
68d74b380f
@ -3545,10 +3545,12 @@ avahi_service_browser_new_cb (GObject *source_object,
|
||||
{
|
||||
/*
|
||||
* The creation of ServiceBrowser fails with G_IO_ERROR_DBUS_ERROR
|
||||
* if Avahi is disabled.
|
||||
* or a GDBusError such as G_DBUS_ERROR_SERVICE_UNKNOWN if Avahi is disabled.
|
||||
*/
|
||||
if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_DBUS_ERROR) &&
|
||||
!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
|
||||
if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_DBUS_ERROR) ||
|
||||
error->domain == G_DBUS_ERROR)
|
||||
g_debug ("%s #%d: %s", g_quark_to_string (error->domain), error->code, error->message);
|
||||
else if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
|
||||
g_warning ("%s", error->message);
|
||||
g_error_free (error);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user