mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
Fix max snapshot size
This commit is contained in:
parent
ee825f42e9
commit
610976eddd
|
@ -1822,7 +1822,7 @@ void CClient::ProcessServerPacket(CNetChunk *pPacket)
|
||||||
|
|
||||||
pData = (const char *)Unpacker.GetRaw(PartSize);
|
pData = (const char *)Unpacker.GetRaw(PartSize);
|
||||||
|
|
||||||
if(Unpacker.Error() || NumParts < 1 || NumParts > CSnapshot::MAX_PARTS || Part < 0 || Part >= NumParts || PartSize < 0 || PartSize > MAX_SNAPSHOT_PACKSIZE)
|
if(Unpacker.Error() || NumParts < 1 || NumParts > CSnapshot::MAX_PARTS || Part < 0 || Part >= NumParts || PartSize < 0 || PartSize >= MAX_SNAPSHOT_PACKSIZE)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if(GameTick >= m_CurrentRecvTick[g_Config.m_ClDummy])
|
if(GameTick >= m_CurrentRecvTick[g_Config.m_ClDummy])
|
||||||
|
@ -2087,7 +2087,7 @@ void CClient::ProcessServerPacketDummy(CNetChunk *pPacket)
|
||||||
|
|
||||||
pData = (const char *)Unpacker.GetRaw(PartSize);
|
pData = (const char *)Unpacker.GetRaw(PartSize);
|
||||||
|
|
||||||
if(Unpacker.Error() || NumParts < 1 || NumParts > CSnapshot::MAX_PARTS || Part < 0 || Part >= NumParts || PartSize < 0 || PartSize > MAX_SNAPSHOT_PACKSIZE)
|
if(Unpacker.Error() || NumParts < 1 || NumParts > CSnapshot::MAX_PARTS || Part < 0 || Part >= NumParts || PartSize < 0 || PartSize >= MAX_SNAPSHOT_PACKSIZE)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if(GameTick >= m_CurrentRecvTick[!g_Config.m_ClDummy])
|
if(GameTick >= m_CurrentRecvTick[!g_Config.m_ClDummy])
|
||||||
|
|
Loading…
Reference in a new issue