0
mirror of https://github.com/XTLS/Xray-core.git synced 2025-06-12 03:19:36 +03:00

vformat supports multi-core processing (#757)

* Feat: vformat supports multi-core processing (#996)

Co-authored-by: Loyalsoldier <10487845+Loyalsoldier@users.noreply.github.com>
This commit is contained in:
yuhan6665
2021-10-12 11:29:22 -04:00
committed by GitHub
parent a97d45c93a
commit 3554886ce1
4 changed files with 24 additions and 23 deletions

View File

@ -87,8 +87,7 @@ func (s *Service) Subscribe(name string) *Subscriber {
done: done.New(),
}
s.Lock()
subs := append(s.subs[name], sub)
s.subs[name] = subs
s.subs[name] = append(s.subs[name], sub)
s.Unlock()
common.Must(s.ctask.Start())
return sub