Use ring buffer for network TCP packet send queue

This commit is contained in:
Jonathan G Rennison
2023-08-18 21:05:06 +01:00
parent cf655f624b
commit 175f6c979c
3 changed files with 16 additions and 3 deletions

View File

@@ -1179,7 +1179,11 @@ NetworkRecvStatus ServerNetworkGameSocketHandler::Receive_CLIENT_MAP_OK(Packet *
this->SendConfigUpdate();
/* quickly update the syncing client with company details */
return this->SendCompanyUpdate();
NetworkRecvStatus status = this->SendCompanyUpdate();
this->ShrinkToFitSendQueue();
return status;
}
/* Wrong status for this packet, give a warning to client, and close connection */