diff --git a/main.go b/main.go index 2e225fa3ff8e7dce49933f9082e5034f61b674fd..b6c5697dc15b22c326d184a6c7a81b8ce03f5edd 100644 --- a/main.go +++ b/main.go @@ -254,7 +254,9 @@ func serverWebsocket(w http.ResponseWriter, r *http.Request) { logger.Errorf("processRoomHeartbeat fail:%v", err) } } else if msgType == common.MsgTypeGroupMicChangeRsp { - logger.Infof("common.MsgTypeGroupMicChangeRsp arrive") + if err := processGroupMicChangeRsp(logger, ci.Uid, pbData); err != nil { + logger.Errorf("processGroupMicChangeRsp fail:%v", err) + } } else { logger.Warnf("Unknown message type %d", msgType) } @@ -463,6 +465,17 @@ func processRoomHeartbeat(logger *log.Entry, uid uint64, pbData []byte) error { } } +func processGroupMicChangeRsp(logger *log.Entry, uid uint64, pbData []byte) error { + msg := &userProxy.GroupMicChangeRsp{} + err := proto.Unmarshal(pbData, msg) + if err == nil { + logger.Infof("groupMicChangeRsp,uid:%v,seqId:%v", uid, msg.SeqId) + } else { + return err + } + return err +} + // 直接发匹配成功消息,调试用 func homePage(w http.ResponseWriter, r *http.Request) { rsp := "Home Page"