ss_forcclosesocket

This commit is contained in:
aozhiwei 2019-05-30 13:34:35 +08:00
parent e43f0aa759
commit bd805d6095
3 changed files with 9 additions and 0 deletions

View File

@ -8,6 +8,7 @@ enum SSMessageId_e
_SS_WSP_SocketDisconnect = 10;
_SS_WSP_RequestTargetServer = 11;
_SS_MS_ResponseTargetServer = 12;
_SS_ForceCloseSocket = 13;
_SS_CMPing = 101;
_SS_SMRpcError = 102;

View File

@ -52,3 +52,7 @@ message SS_Pong
{
optional int32 param1 = 1;
}
message SS_ForceCloseSocket
{
}

View File

@ -410,6 +410,10 @@ void App::ProcessMasterServerMsg(f8::MsgHdr& hdr)
void App::ProcessTargetServerMsg(f8::MsgHdr& hdr)
{
if (hdr.msgid == ss::_SS_ForceCloseSocket) {
GCListener::Instance()->ForceCloseClient(hdr.socket_handle);
return;
}
if (hdr.msgid < 100) {
return;
}