mirror of
https://github.com/yusing/godoxy.git
synced 2025-05-20 04:42:33 +02:00
release filewatcher channels
This commit is contained in:
parent
ba8705fb84
commit
4819972399
1 changed files with 4 additions and 0 deletions
|
@ -88,6 +88,10 @@ func (h *DirWatcher) cleanup() {
|
|||
h.w.Close()
|
||||
close(h.eventCh)
|
||||
close(h.errCh)
|
||||
h.fwMap.RangeAll(func(key string, fw *fileWatcher) {
|
||||
close(fw.eventCh)
|
||||
close(fw.errCh)
|
||||
})
|
||||
h.task.Finish(nil)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue