engine: client: correctly skip message that would overflow temp entity buffer

This commit is contained in:
Alibek Omarov
2026-05-16 20:59:57 +05:00
parent d305292340
commit fc4b982ecc

View File

@@ -1900,7 +1900,11 @@ void CL_ParseTempEntity( sizebuf_t *msg, connprotocol_t proto )
// this will probably be fatal anyway
if( iSize > sizeof( msg_data ))
{
Con_Printf( S_ERROR "%s: Temp buffer overflow!\n", __func__ );
MSG_SeekToBit( msg, iSize << 3, SEEK_CUR );
return;
}
// parse user message into buffer
MSG_ReadBytes( msg, msg_data, iSize );