Debian patch: 310_segfault_noGLX.diff SDL-1.2
authorSam Lantinga <slouken@libsdl.org>
Sat, 10 Oct 2009 10:10:36 +0000
branchSDL-1.2
changeset 4312 f2f8525e60c2
parent 4311 1238da4a7112
child 4313 8ec3036098df
Debian patch: 310_segfault_noGLX.diff
src/video/x11/SDL_x11gl.c
--- a/src/video/x11/SDL_x11gl.c	Sat Oct 10 10:09:01 2009 +0000
+++ b/src/video/x11/SDL_x11gl.c	Sat Oct 10 10:10:36 2009 +0000
@@ -77,6 +77,11 @@
 	/* It takes a bit of care to be fool-proof about parsing the
 	 * OpenGL extensions string. Don't be fooled by sub-strings, etc.
 	 */
+
+	/* http://bugs.debian.org/537487 */
+	if (extensions == NULL) {
+	      return 0;
+	}
 	
 	start = extensions;