mirror of
https://github.com/Mrs4s/MiraiGo.git
synced 2025-05-04 19:17:38 +08:00
fix bug.
This commit is contained in:
parent
14d741fe93
commit
7a99648b00
@ -103,6 +103,7 @@ func NewClientMd5(uin int64, passwordMd5 [16]byte) *QQClient {
|
||||
decoders: map[string]func(*QQClient, uint16, []byte) (interface{}, error){
|
||||
"wtlogin.login": decodeLoginResponse,
|
||||
"StatSvc.register": decodeClientRegisterResponse,
|
||||
"StatSvc.ReqMSFOffline": decodeMSFOfflinePacket,
|
||||
"MessageSvc.PushNotify": decodeSvcNotify,
|
||||
"OnlinePush.PbPushGroupMsg": decodeGroupMessagePacket,
|
||||
"OnlinePush.ReqPush": decodeOnlinePushReqPacket,
|
||||
|
@ -672,6 +672,13 @@ func decodeForceOfflinePacket(c *QQClient, _ uint16, payload []byte) (interface{
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
func decodeMSFOfflinePacket(c *QQClient, _ uint16, _ []byte) (interface{}, error) {
|
||||
if c.Online {
|
||||
c.Online = false
|
||||
c.dispatchDisconnectEvent(&ClientDisconnectedEvent{Message: "服务器端强制下线."})
|
||||
}
|
||||
}
|
||||
|
||||
func decodeMultiApplyUpResponse(c *QQClient, _ uint16, payload []byte) (interface{}, error) {
|
||||
body := multimsg.MultiRspBody{}
|
||||
if err := proto.Unmarshal(payload, &body); err != nil {
|
||||
|
Loading…
x
Reference in New Issue
Block a user