From: Matthias Clasen Date: Sun, 11 Mar 2018 12:14:14 +0000 (-0400) Subject: Exit cleanly if no display is found X-Git-Tag: archive/raspbian/4.4.1+ds1-2+rpi1^2~18^2~22^2~1025 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=da8e83f9cb268173aa006f5c631f5c2b56f4858f;p=gtk4.git Exit cleanly if no display is found We should not try to create an inspector window and generate tons of ugly warnings in this case. --- diff --git a/gtk/gtkmain.c b/gtk/gtkmain.c index 395a470c57..336c9363ae 100644 --- a/gtk/gtkmain.c +++ b/gtk/gtkmain.c @@ -777,7 +777,7 @@ gtk_init_check (void) ret = gdk_display_open_default () != NULL; - if (gtk_get_debug_flags () & GTK_DEBUG_INTERACTIVE) + if (ret && (gtk_get_debug_flags () & GTK_DEBUG_INTERACTIVE)) gtk_window_set_interactive_debugging (TRUE); return ret;