|
|
@ -1,4 +1,5 @@ |
|
|
|
// Copyright (c) 2010 Satoshi Nakamoto
|
|
|
|
// Copyright (c) 2010 Satoshi Nakamoto
|
|
|
|
|
|
|
|
// Copyright (c) 2011 The Bitcoin developers
|
|
|
|
// Distributed under the MIT/X11 software license, see the accompanying
|
|
|
|
// Distributed under the MIT/X11 software license, see the accompanying
|
|
|
|
// file license.txt or http://www.opensource.org/licenses/mit-license.php.
|
|
|
|
// file license.txt or http://www.opensource.org/licenses/mit-license.php.
|
|
|
|
|
|
|
|
|
|
|
@ -1187,7 +1188,8 @@ Value listtransactions(const Array& params, bool fHelp) |
|
|
|
|
|
|
|
|
|
|
|
// Now: iterate backwards until we have nCount items to return:
|
|
|
|
// Now: iterate backwards until we have nCount items to return:
|
|
|
|
TxItems::reverse_iterator it = txByTime.rbegin(); |
|
|
|
TxItems::reverse_iterator it = txByTime.rbegin(); |
|
|
|
for (std::advance(it, nFrom); it != txByTime.rend(); ++it) |
|
|
|
if (txByTime.size() > nFrom) std::advance(it, nFrom); |
|
|
|
|
|
|
|
for (; it != txByTime.rend(); ++it) |
|
|
|
{ |
|
|
|
{ |
|
|
|
CWalletTx *const pwtx = (*it).second.first; |
|
|
|
CWalletTx *const pwtx = (*it).second.first; |
|
|
|
if (pwtx != 0) |
|
|
|
if (pwtx != 0) |
|
|
|