aboutsummaryrefslogtreecommitdiff
path: root/src/init.cpp
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2014-10-22 10:46:24 +0200
committerWladimir J. van der Laan <laanwj@gmail.com>2014-10-22 10:47:14 +0200
commitf984c7d7adf40e8517437f7b8c3704a63e1ca034 (patch)
treef26d6b80e8a8cb3e38388d9990f53215dc6cd4a1 /src/init.cpp
parent7305620599c8fc7d152bb0c0c0bbe162c6c1a912 (diff)
parenta873823864a00f68772eb2b85a70e933839ca3f5 (diff)
downloadbitcoin-f984c7d7adf40e8517437f7b8c3704a63e1ca034.tar.xz
Merge pull request #5108
a873823 CAutoFile: Explicit Get() and remove unused methods (Wladimir J. van der Laan) fef24ca Add IsNull() to class CAutoFile and remove operator ! (Ruben Dario Ponticeli)
Diffstat (limited to 'src/init.cpp')
-rw-r--r--src/init.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/init.cpp b/src/init.cpp
index 743cdd4386..70ac5190d3 100644
--- a/src/init.cpp
+++ b/src/init.cpp
@@ -139,7 +139,7 @@ void Shutdown()
{
boost::filesystem::path est_path = GetDataDir() / FEE_ESTIMATES_FILENAME;
CAutoFile est_fileout(fopen(est_path.string().c_str(), "wb"), SER_DISK, CLIENT_VERSION);
- if (est_fileout)
+ if (!est_fileout.IsNull())
mempool.WriteFeeEstimates(est_fileout);
else
LogPrintf("%s: Failed to write fee estimates to %s\n", __func__, est_path.string());
@@ -1064,7 +1064,7 @@ bool AppInit2(boost::thread_group& threadGroup)
boost::filesystem::path est_path = GetDataDir() / FEE_ESTIMATES_FILENAME;
CAutoFile est_filein(fopen(est_path.string().c_str(), "rb"), SER_DISK, CLIENT_VERSION);
// Allowed to fail as this file IS missing on first startup.
- if (est_filein)
+ if (!est_filein.IsNull())
mempool.ReadFeeEstimates(est_filein);
fFeeEstimatesInitialized = true;