...kedbyaddress' doesn't have to iterate through the whole wallet each time.
Proposed fix for #158.
"getstakedbyaddress" is very fast now, at least when you are enquiring about stakes with the default (1) number of confirmations.
I didn't put locks around any of this code. Is it necessary? I suppose it's possible that a block is found (possibly even causing a reorg) while CWallet::SumStakingRewards() is running. Do we need to somehow protect against that?
...kedbyaddress' doesn't have to iterate through the whole wallet each time.
Proposed fix for #158.
"getstakedbyaddress" is very fast now, at least when you are enquiring about stakes with the default (1) number of confirmations.
I didn't put locks around any of this code. Is it necessary? I suppose it's possible that a block is found (possibly even causing a reorg) while CWallet::SumStakingRewards() is running. Do we need to somehow protect against that?