]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
fix crashes on Win64 builds caused by stack overflow in R_DrawRTLight
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 4 Sep 2008 05:56:33 +0000 (05:56 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 4 Sep 2008 05:56:33 +0000 (05:56 +0000)
(reported by Willis)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8488 d7cf8633-e32d-0410-b094-e92efae38249

r_shadow.c

index 067910e5e9dddf1b8f3326d6d478c75aa9848f3c..414560e4395e6de71a0bab9a7033fd71d132b5ee 100644 (file)
@@ -2860,10 +2860,10 @@ void R_DrawRTLight(rtlight_t *rtlight, qboolean visible)
        int numlightentities_noselfshadow;
        int numshadowentities;
        int numshadowentities_noselfshadow;
-       entity_render_t *lightentities[MAX_EDICTS];
-       entity_render_t *lightentities_noselfshadow[MAX_EDICTS];
-       entity_render_t *shadowentities[MAX_EDICTS];
-       entity_render_t *shadowentities_noselfshadow[MAX_EDICTS];
+       static entity_render_t *lightentities[MAX_EDICTS];
+       static entity_render_t *lightentities_noselfshadow[MAX_EDICTS];
+       static entity_render_t *shadowentities[MAX_EDICTS];
+       static entity_render_t *shadowentities_noselfshadow[MAX_EDICTS];
 
        // skip lights that don't light because of ambientscale+diffusescale+specularscale being 0 (corona only lights)
        // skip lights that are basically invisible (color 0 0 0)