Fix potential out of bounds access caused by CM_GridPlane

Coverity doesn't care if there is a warning, out of bounds access is bad.
Don't use memset with non-zero value to fill ints

Coverity reported using value -2 as a bad memset. Really doesn't make sense when filling ints and not bytes too.
Fix potential buffer overflow in PS_ReadPrimitive

Found by Coverity.
Fix unchecked buffer size issues in l_script.c and l_precomp.c

Found by Coverity.
Fix max bans range check in SV_AddBanToList

Adding too many bans would write out of bounds. Found by Coverity.
Have OpenGL2 "map $lightmap" check for NULL tr.lightmaps too

Zero length lightmap lump will have NULL tr.lightmaps.

OpenGL1 already has this check, because r_vertexLight 1
would crash Team Arena. OpenGL2 does not disable loading lightmaps
when r_vertexLight is 1 though, so it does not have that issue.
Fix potential buffer overflow caused by long tcMod args

Found by Coverity.