From 287b357e32c819062666cd33e2e99ff0bf630d7a Mon Sep 17 00:00:00 2001 From: UdjinM6 Date: Sun, 15 Feb 2015 02:20:58 +0300 Subject: [PATCH] fix %% calculation on keypool generation --- src/wallet.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wallet.cpp b/src/wallet.cpp index 7e02367b53..f71cc66dcf 100644 --- a/src/wallet.cpp +++ b/src/wallet.cpp @@ -2466,7 +2466,7 @@ bool CWallet::TopUpKeyPool(unsigned int kpSize) throw runtime_error("TopUpKeyPool() : writing generated key failed"); setKeyPool.insert(nEnd); LogPrintf("keypool added key %d, size=%u\n", nEnd, setKeyPool.size()); - double dProgress = nEnd / 10.f; + double dProgress = 100.f * nEnd / (nTargetSize + 1); std::string strMsg = strprintf(_("Loading wallet... (%3.2f %%)"), dProgress); uiInterface.InitMessage(strMsg); }