fix
This commit is contained in:
parent
1948a60c29
commit
537de58afc
|
@ -75,6 +75,9 @@ func decreaseWebsocketConnectCount(userId, guestId int64) {
|
|||
select {
|
||||
case websocketStat <- data:
|
||||
curWsTotalCount += data.Num
|
||||
if curWsTotalCount < 0 {
|
||||
curWsTotalCount = 0
|
||||
}
|
||||
return
|
||||
case <-time.After(time.Millisecond * 200):
|
||||
logx.Error("decreaseWebsocketConnectCount 输入管道超时,丢弃消息")
|
||||
|
@ -111,6 +114,9 @@ func decreaseCombineRequestCount(userId, guestId int64) {
|
|||
select {
|
||||
case websocketStat <- data:
|
||||
curCombineTotalCount += data.Num
|
||||
if curCombineTotalCount < 0 {
|
||||
curCombineTotalCount = 0
|
||||
}
|
||||
return
|
||||
case <-time.After(time.Millisecond * 200):
|
||||
logx.Error("decreaseCombineRequestCount 输入管道超时,丢弃消息")
|
||||
|
@ -165,6 +171,9 @@ func decreaseUnityRequestCount(userId, guestId int64) {
|
|||
select {
|
||||
case websocketStat <- data:
|
||||
curUnityHandleTotalCount += data.Num
|
||||
if curUnityHandleTotalCount < 0 {
|
||||
curUnityHandleTotalCount = 0
|
||||
}
|
||||
return
|
||||
case <-time.After(time.Millisecond * 200):
|
||||
logx.Error("decreaseUnityRequestCount 输入管道超时,丢弃消息")
|
||||
|
|
Loading…
Reference in New Issue
Block a user