mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-21 15:50:07 +01:00
refactor, blockstorage: Replace blocksdir arg
Add a blocks_dir field to the BlockManager options. Move functions relying on the global gArgs to get the blocks_dir into the BlockManager class. This should eventually allow users of the BlockManager to not rely on the global Args and instead pass in their own options.
This commit is contained in:
@@ -5,6 +5,8 @@
|
||||
#ifndef BITCOIN_KERNEL_BLOCKMANAGER_OPTS_H
|
||||
#define BITCOIN_KERNEL_BLOCKMANAGER_OPTS_H
|
||||
|
||||
#include <util/fs.h>
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
class CChainParams;
|
||||
@@ -19,6 +21,7 @@ struct BlockManagerOpts {
|
||||
const CChainParams& chainparams;
|
||||
uint64_t prune_target{0};
|
||||
bool fast_prune{false};
|
||||
const fs::path blocks_dir;
|
||||
};
|
||||
|
||||
} // namespace kernel
|
||||
|
||||
Reference in New Issue
Block a user