From d18bbc6f5be2ec33445fc8e7ba5e7b9572c23e0c Mon Sep 17 00:00:00 2001 From: "Eduardo Lima (Etrunko)" Date: Fri, 26 Feb 2016 17:04:46 -0300 Subject: [PATCH] Don't open the default display while parsing command line MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since commit a9ce19f it has not been possible to check app version from a tty without X session running. The issue is that gtk_get_option_group function opens the default display if passed TRUE as argument. Signed-off-by: Eduardo Lima (Etrunko) Acked-by: Fabiano FidĂȘncio --- src/virt-viewer-app.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/virt-viewer-app.c b/src/virt-viewer-app.c index d31acd3..3fa80a5 100644 --- a/src/virt-viewer-app.c +++ b/src/virt-viewer-app.c @@ -1920,7 +1920,7 @@ virt_viewer_app_local_command_line (GApplication *gapp, g_option_context_set_main_group(context, group); VIRT_VIEWER_APP_GET_CLASS(self)->add_option_entries(self, context, group); - g_option_context_add_group(context, gtk_get_option_group(TRUE)); + g_option_context_add_group(context, gtk_get_option_group(FALSE)); #ifdef HAVE_GTK_VNC g_option_context_add_group(context, vnc_display_get_option_group());