Fix missing unlock in uniquequeue (#9791)
This commit is contained in:
parent
6d1f7e90cf
commit
dbe6136348
1 changed files with 1 additions and 0 deletions
|
@ -82,6 +82,7 @@ func (q *UniqueQueue) AddFunc(id interface{}, fn func()) {
|
|||
idStr := com.ToStr(id)
|
||||
q.table.lock.Lock()
|
||||
if _, ok := q.table.pool[idStr]; ok {
|
||||
q.table.lock.Unlock()
|
||||
return
|
||||
}
|
||||
q.table.pool[idStr] = struct{}{}
|
||||
|
|
Reference in a new issue