From 0a39e8f1ed9633614064228f0fcb52a06c701579 Mon Sep 17 00:00:00 2001 From: jl777 Date: Sun, 13 Nov 2016 07:53:14 -0300 Subject: [PATCH] test --- src/komodo_bitcoind.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/komodo_bitcoind.h b/src/komodo_bitcoind.h index eaf1ee638..7d13977a7 100644 --- a/src/komodo_bitcoind.h +++ b/src/komodo_bitcoind.h @@ -449,13 +449,16 @@ void komodo_index2pubkey33(uint8_t *pubkey33,CBlockIndex *pindex,int32_t height) int8_t komodo_minerid(int32_t height) { + static uint32_t depth; int32_t notaryid; CBlockIndex *pindex; uint8_t pubkey33[33]; - if ( height <= CURRENT_HEIGHT )//chainActive.Tip()->nHeight ) + if ( depth == 0 && height <= CURRENT_HEIGHT )//chainActive.Tip()->nHeight ) { if ( (pindex= chainActive[height]) != 0 ) { + depth++; komodo_index2pubkey33(pubkey33,pindex,height); komodo_chosennotary(¬aryid,height,pubkey33); + depth--; return(notaryid); } }