Merge pull request #1296 from Diapolo/CheckDiskSpace
make CheckDiskSpace() use 50 * 1024 * 1024 Bytes
This commit is contained in:
commit
973ca019bc
@ -1851,11 +1851,11 @@ bool CheckDiskSpace(uint64 nAdditionalBytes)
|
|||||||
{
|
{
|
||||||
uint64 nFreeBytesAvailable = filesystem::space(GetDataDir()).available;
|
uint64 nFreeBytesAvailable = filesystem::space(GetDataDir()).available;
|
||||||
|
|
||||||
// Check for 15MB because database could create another 10MB log file at any time
|
// Check for nMinDiskSpace bytes (currently 50MB)
|
||||||
if (nFreeBytesAvailable < (uint64)15000000 + nAdditionalBytes)
|
if (nFreeBytesAvailable < nMinDiskSpace + nAdditionalBytes)
|
||||||
{
|
{
|
||||||
fShutdown = true;
|
fShutdown = true;
|
||||||
string strMessage = _("Warning: Disk space is low ");
|
string strMessage = _("Warning: Disk space is low");
|
||||||
strMiscWarning = strMessage;
|
strMiscWarning = strMessage;
|
||||||
printf("*** %s\n", strMessage.c_str());
|
printf("*** %s\n", strMessage.c_str());
|
||||||
ThreadSafeMessageBox(strMessage, "Bitcoin", wxOK | wxICON_EXCLAMATION | wxMODAL);
|
ThreadSafeMessageBox(strMessage, "Bitcoin", wxOK | wxICON_EXCLAMATION | wxMODAL);
|
||||||
|
@ -71,8 +71,8 @@ extern unsigned char pchMessageStart[4];
|
|||||||
// Settings
|
// Settings
|
||||||
extern int64 nTransactionFee;
|
extern int64 nTransactionFee;
|
||||||
|
|
||||||
|
// Minimum disk space required - used in CheckDiskSpace()
|
||||||
|
static const uint64 nMinDiskSpace = 52428800;
|
||||||
|
|
||||||
|
|
||||||
class CReserveKey;
|
class CReserveKey;
|
||||||
|
Loading…
Reference in New Issue
Block a user