Skip to content

Commit

Permalink
BugFix: Move TestingSetup::ECCVerifyHandle member to BasicTestingSetup.
Browse files Browse the repository at this point in the history
As the libsecp256k1 context was only initialized in the TestingSetup, we have been forced to use it when sometimes it is not necessary (TestingSetup is a complete setup that includes CConnman, scheduler, validation interface, etc).
  • Loading branch information
furszy committed Apr 20, 2021
1 parent 5844452 commit a821b0b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/test/test_pivx.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ static inline std::vector<unsigned char> InsecureRandBytes(size_t len) { return
* This just configures logging and chain parameters.
*/
struct BasicTestingSetup {
ECCVerifyHandle globalVerifyHandle;

BasicTestingSetup(const std::string& chainName = CBaseChainParams::MAIN);
~BasicTestingSetup();
};
Expand All @@ -49,7 +51,6 @@ struct TestingSetup: public BasicTestingSetup {
boost::thread_group threadGroup;
CConnman* connman;
CScheduler scheduler;
ECCVerifyHandle globalVerifyHandle;

TestingSetup(const std::string& chainName = CBaseChainParams::MAIN);
~TestingSetup();
Expand Down

0 comments on commit a821b0b

Please sign in to comment.