[Pkg-bitcoin-devel] Bug#696715: bitcoin-qt: Should not exit when disk space is low
Petter Reinholdtsen
pere at hungry.com
Wed Dec 26 11:19:34 UTC 2012
Package: bitcoind
Version: 0.7.2-1
The bitcoin client exits when the disk space is running low while
downloading blocks. This is not the most elegant way to handle it, as
the daemon from a user perspective just disappers without a trace. A
better way would be to pause the block downloading until the disk space
situation improves. The CheckDiskSpace() function in src/main.cpp is
the one triggering this behaviour. It contain this code:
// Check for nMinDiskSpace bytes (currently 50MB)
if (nFreeBytesAvailable < nMinDiskSpace + nAdditionalBytes)
{
fShutdown = true;
string strMessage = _("Warning: Disk space is low!");
strMiscWarning = strMessage;
printf("*** %s\n", strMessage.c_str());
uiInterface.ThreadSafeMessageBox(strMessage, "Bitcoin", CClientUIInterface::OK | CClientUIInterface::ICON_EXCLAMATION | CClientUIInterface::MODAL);
StartShutdown();
return false;
}
I noticed the problem with bitcoin-qt, where a dialog about "disk full"
is shown and when I click 'OK' the program just disappears. The code
seem to affect bitcoind too.
--
Happy hacking
Petter Reinholdtsen
More information about the Pkg-bitcoin-devel
mailing list