diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2014-02-24 09:08:56 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2014-02-24 09:08:56 +0100 |
commit | f48742c2bf6002f7c1afaf1d1723659b85d4a3ac (patch) | |
tree | 70025f3ea0d6ad42058dbcf034180d0c961d305b /src/wallet.cpp | |
parent | 4fd082ded7af28929e909843eba5c801fe755257 (diff) |
Get rid of C99 PRI?64 usage in source files
Amend to d5f1e72. It turns out that BerkelyDB was including inttypes.h
indirectly, so we cannot fix this with just macros.
Trivial commit: apply the following script to all .cpp and .h files:
# Middle
sed -i 's/"PRIx64"/x/g' "$1"
sed -i 's/"PRIu64"/u/g' "$1"
sed -i 's/"PRId64"/d/g' "$1"
# Initial
sed -i 's/PRIx64"/"x/g' "$1"
sed -i 's/PRIu64"/"u/g' "$1"
sed -i 's/PRId64"/"d/g' "$1"
# Trailing
sed -i 's/"PRIx64/x"/g' "$1"
sed -i 's/"PRIu64/u"/g' "$1"
sed -i 's/"PRId64/d"/g' "$1"
After this commit, `git grep` for PRI.64 should turn up nothing except
the defines in util.h.
Diffstat (limited to 'src/wallet.cpp')
-rw-r--r-- | src/wallet.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/wallet.cpp b/src/wallet.cpp index 2119098595..c78f47ff04 100644 --- a/src/wallet.cpp +++ b/src/wallet.cpp @@ -1693,7 +1693,7 @@ bool CWallet::NewKeyPool() walletdb.WritePool(nIndex, CKeyPool(GenerateNewKey())); setKeyPool.insert(nIndex); } - LogPrintf("CWallet::NewKeyPool wrote %"PRId64" new keys\n", nKeys); + LogPrintf("CWallet::NewKeyPool wrote %d new keys\n", nKeys); } return true; } @@ -1723,7 +1723,7 @@ bool CWallet::TopUpKeyPool(unsigned int kpSize) if (!walletdb.WritePool(nEnd, CKeyPool(GenerateNewKey()))) throw runtime_error("TopUpKeyPool() : writing generated key failed"); setKeyPool.insert(nEnd); - LogPrintf("keypool added key %"PRId64", size=%"PRIszu"\n", nEnd, setKeyPool.size()); + LogPrintf("keypool added key %d, size=%"PRIszu"\n", nEnd, setKeyPool.size()); } } return true; @@ -1752,7 +1752,7 @@ void CWallet::ReserveKeyFromKeyPool(int64_t& nIndex, CKeyPool& keypool) if (!HaveKey(keypool.vchPubKey.GetID())) throw runtime_error("ReserveKeyFromKeyPool() : unknown key in key pool"); assert(keypool.vchPubKey.IsValid()); - LogPrintf("keypool reserve %"PRId64"\n", nIndex); + LogPrintf("keypool reserve %d\n", nIndex); } } @@ -1779,7 +1779,7 @@ void CWallet::KeepKey(int64_t nIndex) CWalletDB walletdb(strWalletFile); walletdb.ErasePool(nIndex); } - LogPrintf("keypool keep %"PRId64"\n", nIndex); + LogPrintf("keypool keep %d\n", nIndex); } void CWallet::ReturnKey(int64_t nIndex) @@ -1789,7 +1789,7 @@ void CWallet::ReturnKey(int64_t nIndex) LOCK(cs_wallet); setKeyPool.insert(nIndex); } - LogPrintf("keypool return %"PRId64"\n", nIndex); + LogPrintf("keypool return %d\n", nIndex); } bool CWallet::GetKeyFromPool(CPubKey& result) |