File mozilla-break_hanging_glxtest.patch of Package MozillaFirefox
# HG changeset patch
# Parent 320c73a859554e396ae7d5c9758987086c7a1b34
# request waking signal in GLX test - this ensures it doesn't hang on problems
# caused by e.g. cross-endianness X connections
# see bnc#744629 and bnc#744625 for more details
# Parent 1a04b3f212a58a2c3a739c1d174ad2e3431d51de
diff --git a/toolkit/xre/glxtest.cpp b/toolkit/xre/glxtest.cpp
--- a/toolkit/xre/glxtest.cpp
+++ b/toolkit/xre/glxtest.cpp
@@ -166,16 +166,18 @@ void glxtest()
#ifdef __OpenBSD__
#define LIBGL_FILENAME "libGL.so"
#else
#define LIBGL_FILENAME "libGL.so.1"
#endif
void *libgl = dlopen(LIBGL_FILENAME, RTLD_LAZY);
if (!libgl)
fatal_error("Unable to load " LIBGL_FILENAME);
+
+ alarm(3);
typedef void* (* PFNGLXGETPROCADDRESS) (const char *);
PFNGLXGETPROCADDRESS glXGetProcAddress = cast<PFNGLXGETPROCADDRESS>(dlsym(libgl, "glXGetProcAddress"));
if (!glXGetProcAddress)
fatal_error("Unable to find glXGetProcAddress in " LIBGL_FILENAME);
typedef GLXFBConfig* (* PFNGLXQUERYEXTENSION) (Display *, int *, int *);