From 8a522623fc0f7b1c7e15cf57ea34b201bbb88b4d Mon Sep 17 00:00:00 2001 From: Zack Middleton Date: Sat, 25 Jan 2014 21:14:32 -0600 Subject: Check for buffer overflow for rail/lightning surfaces --- src/renderergl1/tr_surface.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/renderergl1') diff --git a/src/renderergl1/tr_surface.c b/src/renderergl1/tr_surface.c index 8f0905e7..8bb01229 100644 --- a/src/renderergl1/tr_surface.c +++ b/src/renderergl1/tr_surface.c @@ -345,6 +345,8 @@ static void DoRailCore( const vec3_t start, const vec3_t end, const vec3_t up, f int vbase; float t = len / 256.0f; + RB_CHECKOVERFLOW( 4, 6 ); + vbase = tess.numVertexes; spanWidth2 = -spanWidth; -- cgit