From 9a859844f496158b8237bbd08ff0f608dc5a6385 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Sat, 19 Aug 2017 19:36:51 +0100 Subject: Toggle SAFE syncmode on and off automatically If monerod is started with default sync mode, set it to SAFE after synchronization completes. Set it back to FAST if synchronization restarts (e.g. because another peer has a longer blockchain). If monerod is started with an explicit sync mode, none of this automation takes effect. --- tests/unit_tests/hardfork.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'tests/unit_tests') diff --git a/tests/unit_tests/hardfork.cpp b/tests/unit_tests/hardfork.cpp index 598b3b7b2..c30feb461 100644 --- a/tests/unit_tests/hardfork.cpp +++ b/tests/unit_tests/hardfork.cpp @@ -47,6 +47,7 @@ public: virtual void open(const std::string& filename, const int db_flags = 0) { } virtual void close() {} virtual void sync() {} + virtual void safesyncmode(const bool onoff) {} virtual void reset() {} virtual std::vector get_filenames() const { return std::vector(); } virtual std::string get_db_name() const { return std::string(); } -- cgit v1.2.3