Browse Source

engine: client: make temp entity buffer larger in case of long textmessages

pull/2/head
Alibek Omarov 2 years ago
parent
commit
af8febabd1
  1. 6
      engine/client/cl_tent.c

6
engine/client/cl_tent.c

@ -1904,7 +1904,7 @@ handle temp-entity messages @@ -1904,7 +1904,7 @@ handle temp-entity messages
void CL_ParseTempEntity( sizebuf_t *msg )
{
sizebuf_t buf;
byte pbuf[256];
byte pbuf[2048];
int iSize;
int type, color, count, flags;
int decalIndex, modelIndex, entityIndex;
@ -1923,6 +1923,10 @@ void CL_ParseTempEntity( sizebuf_t *msg ) @@ -1923,6 +1923,10 @@ void CL_ParseTempEntity( sizebuf_t *msg )
decalIndex = modelIndex = entityIndex = 0;
// this will probably be fatal anyway
if( iSize > sizeof( pbuf ))
Con_Printf( S_ERROR "%s: Temp buffer overflow!\n", __FUNCTION__ );
// parse user message into buffer
MSG_ReadBytes( msg, pbuf, iSize );

Loading…
Cancel
Save