aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--external/CMakeLists.txt3
-rw-r--r--external/miniupnpc/CMakeLists.txt2
-rw-r--r--src/cryptonote_core/cryptonote_core.cpp2
-rw-r--r--src/cryptonote_core/tx_pool.cpp6
4 files changed, 8 insertions, 5 deletions
diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt
index eb6a1f294..d13f67b90 100644
--- a/external/CMakeLists.txt
+++ b/external/CMakeLists.txt
@@ -60,9 +60,6 @@ else()
message(STATUS "Using miniupnpc from local source tree (/external/miniupnpc)")
endif()
- set(UPNPC_BUILD_STATIC ON CACHE BOOL "Build static library")
- set(UPNPC_BUILD_SHARED OFF CACHE BOOL "Build shared library")
- set(UPNPC_BUILD_TESTS OFF CACHE BOOL "Build test executables")
add_subdirectory(miniupnpc)
set_property(TARGET upnpc-static PROPERTY FOLDER "external")
diff --git a/external/miniupnpc/CMakeLists.txt b/external/miniupnpc/CMakeLists.txt
index 33fa8d663..51331ecb5 100644
--- a/external/miniupnpc/CMakeLists.txt
+++ b/external/miniupnpc/CMakeLists.txt
@@ -18,7 +18,7 @@ endif()
]]
option (UPNPC_BUILD_STATIC "Build static library" TRUE)
-option (UPNPC_BUILD_SHARED "Build shared library" TRUE)
+option (UPNPC_BUILD_SHARED "Build shared library" FALSE)
if (NOT WIN32)
option (UPNPC_BUILD_TESTS "Build test executables" FALSE)
endif (NOT WIN32)
diff --git a/src/cryptonote_core/cryptonote_core.cpp b/src/cryptonote_core/cryptonote_core.cpp
index 29ea7c57b..608abea19 100644
--- a/src/cryptonote_core/cryptonote_core.cpp
+++ b/src/cryptonote_core/cryptonote_core.cpp
@@ -222,7 +222,7 @@ namespace cryptonote
{
bool r = handle_command_line(vm);
- r = m_mempool.init(m_config_folder);
+ r = m_mempool.init(m_fakechain ? std::string() : m_config_folder);
CHECK_AND_ASSERT_MES(r, false, "Failed to initialize memory pool");
#if BLOCKCHAIN_DB == DB_LMDB
diff --git a/src/cryptonote_core/tx_pool.cpp b/src/cryptonote_core/tx_pool.cpp
index bdd86d3e0..1be44172d 100644
--- a/src/cryptonote_core/tx_pool.cpp
+++ b/src/cryptonote_core/tx_pool.cpp
@@ -612,6 +612,9 @@ namespace cryptonote
CRITICAL_REGION_LOCAL(m_transactions_lock);
m_config_folder = config_folder;
+ if (m_config_folder.empty())
+ return true;
+
std::string state_file_path = config_folder + "/" + CRYPTONOTE_POOLDATA_FILENAME;
boost::system::error_code ec;
if(!boost::filesystem::exists(state_file_path, ec))
@@ -648,6 +651,9 @@ namespace cryptonote
//---------------------------------------------------------------------------------
bool tx_memory_pool::deinit()
{
+ if (m_config_folder.empty())
+ return true;
+
if (!tools::create_directories_if_necessary(m_config_folder))
{
LOG_PRINT_L1("Failed to create data directory: " << m_config_folder);