Codechange: explicitly initialise network pool item related member variables

This commit is contained in:
Rubidium
2025-02-18 21:21:29 +01:00
committed by rubidium42
parent f89924a727
commit d0ba6ed1f4
5 changed files with 14 additions and 14 deletions

View File

@@ -24,7 +24,7 @@ extern NetworkClientSocketPool _networkclientsocket_pool;
class ServerNetworkGameSocketHandler : public NetworkClientSocketPool::PoolItem<&_networkclientsocket_pool>, public NetworkGameSocketHandler, public TCPListenHandler<ServerNetworkGameSocketHandler, PACKET_SERVER_FULL, PACKET_SERVER_BANNED> {
protected:
std::unique_ptr<class NetworkAuthenticationServerHandler> authentication_handler = nullptr; ///< The handler for the authentication.
std::string peer_public_key; ///< The public key of our client.
std::string peer_public_key{}; ///< The public key of our client.
NetworkRecvStatus Receive_CLIENT_JOIN(Packet &p) override;
NetworkRecvStatus Receive_CLIENT_IDENTIFY(Packet &p) override;
@@ -68,7 +68,7 @@ public:
uint8_t last_token = 0; ///< The last random token we did send to verify the client is listening
uint32_t last_token_frame = 0; ///< The last frame we received the right token
ClientStatus status = STATUS_INACTIVE; ///< Status of this client
CommandQueue outgoing_queue; ///< The command-queue awaiting delivery; conceptually more a bucket to gather commands in, after which the whole bucket is sent to the client.
CommandQueue outgoing_queue{}; ///< The command-queue awaiting delivery; conceptually more a bucket to gather commands in, after which the whole bucket is sent to the client.
size_t receive_limit = 0; ///< Amount of bytes that we can receive at this moment
std::shared_ptr<struct PacketWriter> savegame = nullptr; ///< Writer used to write the savegame.