broadway: Quiet initialisation failures
authorBastien Nocera <hadess@hadess.net>
Mon, 11 Oct 2021 11:55:35 +0000 (13:55 +0200)
committerMatthias Clasen <mclasen@redhat.com>
Sun, 31 Oct 2021 21:52:04 +0000 (17:52 -0400)
Broadway is the only GTK+ backend that throws an error on stderr when
failing to initialise, which causes problems when gtk_init_check() is
used and unexpected error output is generated.

This causes hotdoc to fail when generating a GTK plugin's documentation
instead of failing quietly.

"Unable to init server: Could not connect: Connection refused"

gdk/broadway/gdkdisplay-broadway.c

index 59809ca3e42b710fbf0cc023ed106ea4d4b97ee7..cfdbb6f707ff8e2463aed8ec99306e6ab5454117 100644 (file)
@@ -214,7 +214,7 @@ _gdk_broadway_display_open (const char *display_name)
   broadway_display->server = _gdk_broadway_server_new (display, display_name, &error);
   if (broadway_display->server == NULL)
     {
-      g_printerr ("Unable to init Broadway server: %s\n", error->message);
+      g_debug ("Unable to init Broadway server: %s\n", error->message);
       g_error_free (error);
       return NULL;
     }