fix(lotus-sim): really cancel walk immediately
This commit is contained in:
parent
8fffaa5c47
commit
95cf577447
@ -401,12 +401,11 @@ func (sim *Simulation) Walk(
|
||||
grp.Go(func() error {
|
||||
qs := resultQs
|
||||
for len(qs) > 0 {
|
||||
newQs := qs[:0]
|
||||
for _, q := range qs {
|
||||
if err := ctx.Err(); err != nil {
|
||||
return ctx.Err()
|
||||
}
|
||||
|
||||
newQs := qs[:0]
|
||||
for _, q := range qs {
|
||||
select {
|
||||
case r, ok := <-q:
|
||||
if !ok {
|
||||
|
Loading…
Reference in New Issue
Block a user