diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/clientprotocolmsg.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/clientprotocolmsg.h b/include/clientprotocolmsg.h index 863cdf8b2..07f32b686 100644 --- a/include/clientprotocolmsg.h +++ b/include/clientprotocolmsg.h @@ -663,11 +663,14 @@ struct ClientProtocol::Messages::Pong : public ClientProtocol::Message { /** Constructor. * @param cookie Ping cookie. Must remain valid as long as this object is alive. + * @param server Pinged server. Must remain valid as long as this object is alive if non-empty. */ - Pong(const std::string& cookie) + Pong(const std::string& cookie, const std::string& server = "") : ClientProtocol::Message("PONG", ServerInstance->Config->ServerName) { PushParamRef(ServerInstance->Config->ServerName); + if (!server.empty()) + PushParamRef(server); PushParamRef(cookie); } }; |