mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-25 10:43:19 -03:00
blockstorage: Mark FindBlockPos as nodiscard
A false return value indicates a fatal error (disk space being too low), so make sure we always consume this error code. This commit is part of an ongoing process for making the handling of fatal errors more transparent and easier to understand.
This commit is contained in:
parent
f4f1d6d230
commit
5671c15f45
1 changed files with 1 additions and 1 deletions
|
@ -93,7 +93,7 @@ private:
|
|||
EXCLUSIVE_LOCKS_REQUIRED(cs_main);
|
||||
void FlushBlockFile(bool fFinalize = false, bool finalize_undo = false);
|
||||
void FlushUndoFile(int block_file, bool finalize = false);
|
||||
bool FindBlockPos(FlatFilePos& pos, unsigned int nAddSize, unsigned int nHeight, uint64_t nTime, bool fKnown);
|
||||
[[nodiscard]] bool FindBlockPos(FlatFilePos& pos, unsigned int nAddSize, unsigned int nHeight, uint64_t nTime, bool fKnown);
|
||||
bool FindUndoPos(BlockValidationState& state, int nFile, FlatFilePos& pos, unsigned int nAddSize);
|
||||
|
||||
FlatFileSeq BlockFileSeq() const;
|
||||
|
|
Loading…
Add table
Reference in a new issue