mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-06-19 21:31:37 +00:00
ImportChain has two interrupt checkpoints. The one before loading a batch
correctly returns the exported ErrImportInterrupted sentinel, but the one
before inserting a batch returned a freshly constructed
errors.New("interrupted") instead.
The caller in cmd/geth/chaincmd.go detects interruption with
`err == utils.ErrImportInterrupted` to stop processing the remaining
files in a multi-file import. A fresh error value never compares equal to
the sentinel, so an interrupt caught at this checkpoint was treated as an
ordinary per-file failure and the loop kept importing subsequent files.
Return the ErrImportInterrupted sentinel here too so both checkpoints are
recognized by the caller.
|
||
|---|---|---|
| .. | ||
| cmd.go | ||
| diskusage.go | ||
| diskusage_openbsd.go | ||
| diskusage_windows.go | ||
| export_test.go | ||
| flags.go | ||
| flags_legacy.go | ||
| flags_test.go | ||
| history_test.go | ||
| prompt.go | ||