diff options
author | Ryan Ofsky <ryan@ofsky.org> | 2023-07-07 17:32:54 -0400 |
---|---|---|
committer | Ryan Ofsky <ryan@ofsky.org> | 2023-12-04 15:39:15 -0400 |
commit | 213542b625a6a4885fcbdfe236629a5f381eeb05 (patch) | |
tree | fe10697e9196bd5546c372766f74f8fe84182cbe /src/init.h | |
parent | feeb7b816affa790e02e7ba0780c4ef33d2310ff (diff) | |
download | bitcoin-213542b625a6a4885fcbdfe236629a5f381eeb05.tar.xz |
refactor: Add InitContext function to initialize NodeContext with global pointers
Having InitContext() avoids the need to add duplicate code to src/init/*.cpp
files in the next commit. It also lets these files avoid referencing global
variables like gArgs.
There is no change in behavior in this commit.
Diffstat (limited to 'src/init.h')
-rw-r--r-- | src/init.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/init.h b/src/init.h index f27d6120ef..da8255cda3 100644 --- a/src/init.h +++ b/src/init.h @@ -26,6 +26,9 @@ namespace node { struct NodeContext; } // namespace node +/** Initialize node context variables. */ +void InitContext(node::NodeContext& node); + /** Interrupt threads */ void Interrupt(node::NodeContext& node); void Shutdown(node::NodeContext& node); |