File mozilla-break_hanging_glxtest.patch of Package MozillaFirefox.9789

# 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  cf3866dd234f2365591e2e0a13208d96dc0e1625

diff --git a/toolkit/xre/glxtest.cpp b/toolkit/xre/glxtest.cpp
--- a/toolkit/xre/glxtest.cpp
+++ b/toolkit/xre/glxtest.cpp
@@ -128,16 +128,18 @@ void glxtest()
   #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 *);
   PFNGLXQUERYEXTENSION glXQueryExtension = cast<PFNGLXQUERYEXTENSION>(glXGetProcAddress("glXQueryExtension"));