use buffered chan for h.detached

This commit is contained in:
zhongjiajia 2019-01-24 15:46:41 +08:00 committed by Daniel Martí
parent 85ecf4f31f
commit 5dc1e0f3af

View File

@ -89,7 +89,7 @@ func (h *TargetHandler) Run(ctxt context.Context) error {
h.qres = make(chan *cdproto.Message)
h.qevents = make(chan *cdproto.Message)
h.res = make(map[int64]chan *cdproto.Message)
h.detached = make(chan *inspector.EventDetached)
h.detached = make(chan *inspector.EventDetached, 1)
h.pageWaitGroup = new(sync.WaitGroup)
h.domWaitGroup = new(sync.WaitGroup)
h.Unlock()