mirror of
https://github.com/XTLS/Xray-core.git
synced 2026-10-08 22:59:51 +03:00
DNS: Fix pubsub cleanup sizing every topic's slice by the topic count (#7091)
https://github.com/XTLS/Xray-core/pull/7091#pullrequestreview-5414371870
This commit is contained in:
@@ -62,7 +62,7 @@ func (s *Service) Cleanup() error {
|
||||
}
|
||||
|
||||
for name, subs := range s.subs {
|
||||
newSub := make([]*Subscriber, 0, len(s.subs))
|
||||
newSub := make([]*Subscriber, 0, len(subs))
|
||||
for _, sub := range subs {
|
||||
if !sub.IsClosed() {
|
||||
newSub = append(newSub, sub)
|
||||
|
||||
Reference in New Issue
Block a user