diff --git a/eth/stagedsync/exec3.go b/eth/stagedsync/exec3.go index 184300da2..5d80843b7 100644 --- a/eth/stagedsync/exec3.go +++ b/eth/stagedsync/exec3.go @@ -435,6 +435,7 @@ func ExecV3(ctx context.Context, rwLoopG, rwLoopCtx = errgroup.WithContext(rwLoopCtx) defer rwLoopG.Wait() rwLoopG.Go(func() error { + defer rws.Close() defer in.Close() defer applyLoopWg.Wait() return rwLoop(rwLoopCtx)