mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-19 13:27:35 +02:00
Prefer 'unsigned int' for loop index variables tested against ::size()
C++ STL ::size() generally returns unsigned, which implies that "int idx" style of loop variable will generate a signed-vs-unsigned comparison warning when testing the loop exit condition "idx < blah.size()" Update areas of the bitcoin code where loop variables may be more properly and correctly defined as unsigned.
This commit is contained in:
parent
457661f640
commit
faf705a42a
3 changed files with 14 additions and 14 deletions
|
|
@ -1391,8 +1391,8 @@ bool CWallet::TopUpKeyPool()
|
|||
CWalletDB walletdb(strWalletFile);
|
||||
|
||||
// Top up key pool
|
||||
int64 nTargetSize = max(GetArg("-keypool", 100), (int64)0);
|
||||
while (setKeyPool.size() < nTargetSize+1)
|
||||
unsigned int nTargetSize = max(GetArg("-keypool", 100), 0LL);
|
||||
while (setKeyPool.size() < (nTargetSize + 1))
|
||||
{
|
||||
int64 nEnd = 1;
|
||||
if (!setKeyPool.empty())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue