ing
This commit is contained in:
parent
423ec815a2
commit
9f2ff9438c
|
@ -127,6 +127,7 @@ func (s *ProbeServlets) OnDisconnect(servletCtx server.ServletCtx) {
|
|||
}
|
||||
|
||||
func (s *ProbeServlets) handleSubscribe(serverCtx server.ServerCtx, subscribeChan <-chan *ogs.Message) {
|
||||
var sessions []*ogrs.Session
|
||||
|
||||
LOOP:
|
||||
for {
|
||||
|
@ -138,7 +139,12 @@ LOOP:
|
|||
|
||||
switch msg.TargetType {
|
||||
case ogs.PROBE:
|
||||
sessions := s.getProbeSessions(msg.Targets)
|
||||
sessions = s.getProbeSessions(msg.Targets)
|
||||
default:
|
||||
logging.Logger().Warnf("Subscriber: Unknown TargetType %s", msg.TargetType)
|
||||
continue LOOP
|
||||
}
|
||||
|
||||
if nil == sessions || 0 == len(sessions) {
|
||||
continue LOOP
|
||||
}
|
||||
|
@ -150,7 +156,7 @@ LOOP:
|
|||
writeChan <- *msg.Message
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user