diff options
Diffstat (limited to 'src/daemon/core.h')
-rw-r--r-- | src/daemon/core.h | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/daemon/core.h b/src/daemon/core.h index 91dbb7a4b..9a3579e20 100644 --- a/src/daemon/core.h +++ b/src/daemon/core.h @@ -59,16 +59,6 @@ public: : m_core{nullptr} , m_vm_HACK{vm} { - } - - // TODO - get rid of circular dependencies in internals - void set_protocol(t_protocol_raw & protocol) - { - m_core.set_cryptonote_protocol(&protocol); - } - - bool run() - { //initialize core here MGINFO("Initializing core..."); #if defined(PER_BLOCK_CHECKPOINT) @@ -78,9 +68,19 @@ public: #endif if (!m_core.init(m_vm_HACK, nullptr, get_checkpoints)) { - return false; + throw std::runtime_error("Failed to initialize core"); } MGINFO("Core initialized OK"); + } + + // TODO - get rid of circular dependencies in internals + void set_protocol(t_protocol_raw & protocol) + { + m_core.set_cryptonote_protocol(&protocol); + } + + bool run() + { return true; } |