diff options
-rw-r--r-- | external/db_drivers/liblmdb/mdb.c | 2 | ||||
-rw-r--r-- | tests/unit_tests/hardfork.cpp | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/external/db_drivers/liblmdb/mdb.c b/external/db_drivers/liblmdb/mdb.c index ae32c9896..5d57f8b15 100644 --- a/external/db_drivers/liblmdb/mdb.c +++ b/external/db_drivers/liblmdb/mdb.c @@ -2429,7 +2429,7 @@ mdb_page_alloc(MDB_cursor *mc, int num, MDB_page **mp) goto fail; } #ifdef _WIN32 - if (env->me_flags & MDB_WRITEMAP) { + if (!(env->me_flags & MDB_RDONLY)) { void *p; p = (MDB_page *)(env->me_map + env->me_psize * pgno); p = VirtualAlloc(p, env->me_psize * num, MEM_COMMIT, diff --git a/tests/unit_tests/hardfork.cpp b/tests/unit_tests/hardfork.cpp index 56ec155f0..d469dadec 100644 --- a/tests/unit_tests/hardfork.cpp +++ b/tests/unit_tests/hardfork.cpp @@ -128,6 +128,7 @@ public: virtual uint8_t get_hard_fork_version(uint64_t height) const { return versions[height]; } + virtual void check_hard_fork_info() {} private: std::vector<block> blocks; |