aboutsummaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorJim Posen <jim.posen@gmail.com>2019-01-24 11:20:57 -0800
committerJim Posen <jim.posen@gmail.com>2019-02-22 17:38:45 -0800
commit04cca330944f859b4ed68cb8da8a79f5206fd630 (patch)
treea0c42f2d1b123a0c73e3bf3943cbdb18393e441d /src/util
parent4c01e4e159db82ce4b2acce75f709cac996367d7 (diff)
Style cleanup.
Diffstat (limited to 'src/util')
-rw-r--r--src/util/system.cpp8
-rw-r--r--src/util/system.h2
2 files changed, 5 insertions, 5 deletions
diff --git a/src/util/system.cpp b/src/util/system.cpp
index 3e6c2ae5d4..1f0a097e3d 100644
--- a/src/util/system.cpp
+++ b/src/util/system.cpp
@@ -135,12 +135,12 @@ bool DirIsWritable(const fs::path& directory)
return true;
}
-bool CheckDiskSpace(const fs::path& dir, uint64_t nAdditionalBytes)
+bool CheckDiskSpace(const fs::path& dir, uint64_t additional_bytes)
{
- constexpr uint64_t nMinDiskSpace = 52428800; // 50 MiB
+ constexpr uint64_t min_disk_space = 52428800; // 50 MiB
- uint64_t nFreeBytesAvailable = fs::space(dir).available;
- return nFreeBytesAvailable >= nMinDiskSpace + nAdditionalBytes;
+ uint64_t free_bytes_available = fs::space(dir).available;
+ return free_bytes_available >= min_disk_space + additional_bytes;
}
/**
diff --git a/src/util/system.h b/src/util/system.h
index 2a2ee9bc1d..bcfcaaaed0 100644
--- a/src/util/system.h
+++ b/src/util/system.h
@@ -72,7 +72,7 @@ bool RenameOver(fs::path src, fs::path dest);
bool LockDirectory(const fs::path& directory, const std::string lockfile_name, bool probe_only=false);
void UnlockDirectory(const fs::path& directory, const std::string& lockfile_name);
bool DirIsWritable(const fs::path& directory);
-bool CheckDiskSpace(const fs::path& dir, uint64_t nAdditionalBytes = 0);
+bool CheckDiskSpace(const fs::path& dir, uint64_t additional_bytes = 0);
/** Release all directory locks. This is used for unit testing only, at runtime
* the global destructor will take care of the locks.