From 4aea265846f80efd11a8fd80586c721613a13836 Mon Sep 17 00:00:00 2001 From: blackjok3r Date: Mon, 29 Oct 2018 13:34:27 +0800 Subject: [PATCH] try --- src/cc/dice.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cc/dice.cpp b/src/cc/dice.cpp index b39f39dbf..cb6103040 100644 --- a/src/cc/dice.cpp +++ b/src/cc/dice.cpp @@ -684,7 +684,8 @@ int64_t DicePlanFunds(uint64_t &entropyval,uint256 &entropytxid,uint64_t refsbit SetCCunspents(unspentOutputs,coinaddr); entropyval = 0; int loops = 0; - int startfrom = rand()%(unspentOutputs.size()%2); + int numtxs = unspentOutputs.size()/2; + int startfrom = rand()%numtxs; fprintf(stderr, "start from loop: %d\n",startfrom); for (std::vector >::const_iterator it=unspentOutputs.begin(); it!=unspentOutputs.end(); it++) {