2192: Reserve bytes for the type and token r=heinrich5991 a=Learath2

I'm guessing this also caused #2149 

It just required a weird combination of players and name length to trigger (or max packet)...

Co-authored-by: Learath <learath2@gmail.com>
This commit is contained in:
bors[bot] 2020-05-18 18:46:25 +00:00 committed by GitHub
commit 6c1728f3b8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1728,7 +1728,7 @@ void CServer::CacheServerInfo(CCache *pCache, int Type, bool SendClients)
if(Type == SERVERINFO_EXTENDED) if(Type == SERVERINFO_EXTENDED)
{ {
if(pp.Size() >= NET_MAX_PAYLOAD) if(pp.Size() >= NET_MAX_PAYLOAD - 18) // 8 bytes for type, 10 bytes for the largest token
{ {
// Retry current player. // Retry current player.
i--; i--;