fix segv in nolightmapsearch

git-svn-id: svn://svn.icculus.org/netradiant/trunk@368 61c419a2-8eb2-4b30-bcec-8cead039b335
This commit is contained in:
divverent 2009-05-20 17:59:40 +00:00
parent 8b11f84691
commit b81233b07d

View File

@ -2016,7 +2016,7 @@ static void FindOutLightmaps( rawLightmap_t *lm )
y = 0; y = 0;
/* walk the list of lightmap pages */ /* walk the list of lightmap pages */
for( i = noLightmapSearch ? numOutLightmaps - LIGHTMAP_RESERVE_COUNT : 0; i < numOutLightmaps; i++ ) for( i = ((noLightmapSearch && numOutLightmaps >= LIGHTMAP_RESERVE_COUNT) ? (numOutLightmaps - LIGHTMAP_RESERVE_COUNT) : 0); i < numOutLightmaps; i++ )
{ {
/* get the output lightmap */ /* get the output lightmap */
olm = &outLightmaps[ i ]; olm = &outLightmaps[ i ];