diff --git a/src/daemon/main.cpp b/src/daemon/main.cpp index 0cf069636..e500c6030 100644 --- a/src/daemon/main.cpp +++ b/src/daemon/main.cpp @@ -277,17 +277,16 @@ int main(int argc, char const * argv[]) // Check for NTFS compression on both the data folder and the lmdb folder // Compression can corrupt the blockchain on disk - if (isNtfsCompressed(data_dir.c_str())) - { - MERROR("Data directory is using NTFS compression, blockchain might get corrupted."); - } - bf::path db_path {bf::path(data_dir) / "lmdb"}; - if (bf::exists(db_path)) + boost::filesystem::path db_path{data_dir / "lmdb"}; + if (boost::filesystem::exists(db_path)) { if (isNtfsCompressed(db_path.c_str())) - { MERROR("Database directory is using NTFS compression, blockchain might get corrupted."); - } + } + else + { + if (isNtfsCompressed(data_dir.c_str())) + MERROR("Data directory is using NTFS compression, blockchain might get corrupted."); } #endif