mirror of
https://github.com/monero-project/monero.git
synced 2025-01-03 09:29:42 +00:00
only check database directory for compression, fallback to data dir
This commit is contained in:
parent
d9dbc49f3b
commit
ceff273d2a
1 changed files with 7 additions and 8 deletions
|
@ -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
|
||||
|
||||
|
|
Loading…
Reference in a new issue