* key.c (init_key_x11): Don't try to use X11 if DISPLAY is not

set in the environment.
This commit is contained in:
Pavel Roskin 2003-02-23 05:23:04 +00:00
parent 92da7e9dc0
commit 66b2b1381c
2 changed files with 11 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2003-02-23 Pavel Roskin <proski@gnu.org>
* key.c (init_key_x11): Don't try to use X11 if DISPLAY is not
set in the environment.
2003-02-22 Pavel Tsekov <ptsekov@gmx.net>
* key.c: Add support for dynamic loading of libX11.

View File

@ -259,7 +259,7 @@ static Bool (*func_XQueryPointer) (Display *, Window, Window *, Window *,
unsigned int *);
static GModule *x11_module;
#endif /* HAVE_GMODULE */
#endif /* HAVE_GMODULE */
static Display *x11_display;
static Window x11_window;
@ -269,7 +269,12 @@ init_key_x11 (void)
{
#ifdef HAVE_GMODULE
gchar *x11_module_fname;
#endif /* HAVE_GMODULE */
if (!getenv ("DISPLAY"))
return;
#ifdef HAVE_GMODULE
x11_module_fname = g_module_build_path (NULL, "X11");
if (!x11_module_fname)