[Network] Don't allow Event_ListGames to leak info and bloat bandwith

Took 20 minutes
This commit is contained in:
Lukas Brübach 2026-08-23 02:56:06 +02:00
parent 8a5723c0b5
commit 7d5cb3bfc4

View file

@ -829,7 +829,7 @@ void Server_Game::getInfo(ServerInfo_Game &result) const
result.mutable_creator_info()->CopyFrom(*getCreatorInfo());
const Server_AbstractParticipant *host = participants.value(hostId, nullptr);
if (host != nullptr) {
result.mutable_host_info()->CopyFrom(*host->getUserInfo());
host->copyUserInfo(*result.mutable_host_info(), false);
} else {
result.mutable_host_info()->CopyFrom(*getCreatorInfo());
}