diff options
author | Riccardo Spagni <ric@spagni.net> | 2019-03-21 14:44:03 +0200 |
---|---|---|
committer | Riccardo Spagni <ric@spagni.net> | 2019-03-21 14:44:04 +0200 |
commit | 48e3a341f8bb601895c94e7b637475f8911ae530 (patch) | |
tree | 393b21c46c390e9510923da70ce3b934b7b87adc /tests/core_tests/chaingen.h | |
parent | Merge pull request #5208 (diff) | |
parent | tests/trezor: HF9 and HF10 tests (diff) | |
download | monero-48e3a341f8bb601895c94e7b637475f8911ae530.tar.xz |
Merge pull request #5211
c9b13fbb tests/trezor: HF9 and HF10 tests (Dusan Klinec)
a1fd1d49 device/trezor: HF10 support added, wallet::API (Dusan Klinec)
d74d26f2 crypto: hmac_keccak added (Dusan Klinec)
Diffstat (limited to 'tests/core_tests/chaingen.h')
-rw-r--r-- | tests/core_tests/chaingen.h | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/core_tests/chaingen.h b/tests/core_tests/chaingen.h index 8bf5a9b08..f2bcb7787 100644 --- a/tests/core_tests/chaingen.h +++ b/tests/core_tests/chaingen.h @@ -754,7 +754,7 @@ struct get_test_options { }; //-------------------------------------------------------------------------- template<class t_test_class> -inline bool do_replay_events_get_core(std::vector<test_event_entry>& events, cryptonote::core **core) +inline bool do_replay_events_get_core(std::vector<test_event_entry>& events, cryptonote::core *core) { boost::program_options::options_description desc("Allowed options"); cryptonote::core::init_options(desc); @@ -768,8 +768,7 @@ inline bool do_replay_events_get_core(std::vector<test_event_entry>& events, cry if (!r) return false; - *core = new cryptonote::core(nullptr); - auto & c = **core; + auto & c = *core; // FIXME: make sure that vm has arg_testnet_on set to true or false if // this test needs for it to be so. @@ -825,9 +824,9 @@ inline bool replay_events_through_core_validate(std::vector<test_event_entry>& e template<class t_test_class> inline bool do_replay_events(std::vector<test_event_entry>& events) { - cryptonote::core * core; + cryptonote::core core(nullptr); bool ret = do_replay_events_get_core<t_test_class>(events, &core); - core->deinit(); + core.deinit(); return ret; } //-------------------------------------------------------------------------- |