git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5949
d7cf8633-e32d-0410-b094-
e92efae38249
case svc_lightstyle:
i = MSG_ReadByte ();
- if (i >= MAX_LIGHTSTYLES)
- Host_Error ("svc_lightstyle >= MAX_LIGHTSTYLES");
+ if (i >= cl_max_lightstyle)
+ {
+ Con_Printf ("svc_lightstyle >= MAX_LIGHTSTYLES");
+ break;
+ }
strlcpy (cl_lightstyle[i].map, MSG_ReadString(), sizeof (cl_lightstyle[i].map));
cl_lightstyle[i].map[MAX_STYLESTRING - 1] = 0;
cl_lightstyle[i].length = (int)strlen(cl_lightstyle[i].map);