[quake3-commits] r1610 - trunk/code/sdl

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Mon Sep 14 22:51:09 EDT 2009


Author: icculus
Date: 2009-09-14 22:51:09 -0400 (Mon, 14 Sep 2009)
New Revision: 1610

Modified:
   trunk/code/sdl/sdl_glimp.c
Log:
Handle r_colorbits values better.

  Fixes Bugzilla #4244.


Modified: trunk/code/sdl/sdl_glimp.c
===================================================================
--- trunk/code/sdl/sdl_glimp.c	2009-09-15 02:48:17 UTC (rev 1609)
+++ trunk/code/sdl/sdl_glimp.c	2009-09-15 02:51:09 UTC (rev 1610)
@@ -265,10 +265,9 @@
 	else
 		glConfig.isFullscreen = qfalse;
 
-	if (!r_colorbits->value)
+	colorbits = r_colorbits->value;
+	if ((!colorbits) || (colorbits >= 32))
 		colorbits = 24;
-	else
-		colorbits = r_colorbits->value;
 
 	if (!r_depthbits->value)
 		depthbits = 24;



More information about the quake3-commits mailing list