Update sched_worker.go
Avoid possible deadlock by sh.workersLk
This commit is contained in:
parent
bb5a92e2f4
commit
e9cc697ee8
1
extern/sector-storage/sched_worker.go
vendored
1
extern/sector-storage/sched_worker.go
vendored
@ -57,6 +57,7 @@ func (sh *scheduler) runWorker(ctx context.Context, w Worker) error {
|
|||||||
log.Warnw("duplicated worker added", "id", wid)
|
log.Warnw("duplicated worker added", "id", wid)
|
||||||
|
|
||||||
// this is ok, we're already handling this worker in a different goroutine
|
// this is ok, we're already handling this worker in a different goroutine
|
||||||
|
sh.workersLk.Unlock()
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user