From 5268bc2d753a2aa893419dcc5900cd1d25703c08 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Rafa=C3=ABl=20Carr=C3=A9?= Date: Thu, 6 Dec 2007 01:20:26 +0000 Subject: [PATCH] fix #1382 --- modules/gui/qt4/qt4.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/gui/qt4/qt4.cpp b/modules/gui/qt4/qt4.cpp index 6f1ad1e301..686456bda3 100644 --- a/modules/gui/qt4/qt4.cpp +++ b/modules/gui/qt4/qt4.cpp @@ -177,7 +177,8 @@ static int Open( vlc_object_t *p_this ) intf_thread_t *p_intf = (intf_thread_t *)p_this; p_intf->pf_run = Run; #if defined HAVE_GETENV && defined Q_WS_X11 - if( !getenv( "DISPLAY" ) ) + char *psz_display = getenv( "DISPLAY" ); + if( !psz_display || !*psz_display ) { msg_Err(p_intf, "no X server"); return VLC_EGENERIC; -- 2.39.2