From 9cdc0d57bd440bc33ce066125e15cd8601dca5e8 Mon Sep 17 00:00:00 2001 From: jl777 Date: Wed, 14 Mar 2018 17:07:38 +0200 Subject: [PATCH] Test --- iguana/dpow/dpow_rpc.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/iguana/dpow/dpow_rpc.c b/iguana/dpow/dpow_rpc.c index e2637a2ff..f220f83dd 100755 --- a/iguana/dpow/dpow_rpc.c +++ b/iguana/dpow/dpow_rpc.c @@ -58,6 +58,7 @@ int32_t komodo_initjson(char *fname) char *fstr,*field,*hexstr; cJSON *argjson,*array,*item; long fsize; int32_t i,n,num,retval = -1; if ( (fstr= OS_filestr(&fsize,fname)) != 0 ) { + printf("%s.(%s)\n",fname,fstr); if ( (argjson= cJSON_Parse(fstr)) != 0 ) { if ( (num= juint(argjson,"BTCminsigs")) > Notaries_BTCminsigs ) @@ -74,7 +75,13 @@ int32_t komodo_initjson(char *fname) { Notaries_elected[i][0] = clonestr(field); Notaries_elected[i][1] = clonestr(hexstr); - } else break; + printf("%d of %d: %s %s\n",i,n,field,hexstr); + } + else + { + printf("couldnt find (%s) in %s or non-hex (%s)\n",field,jprint(item,0),hexstr!=0?hexstr:""); + break; + } } if ( i == n ) { @@ -91,7 +98,7 @@ int32_t komodo_initjson(char *fname) int32_t komodo_notaries(char *symbol,uint8_t pubkeys[64][33],int32_t height) { - int32_t i,num=-1; struct iguana_info *coin; char params[256],*retstr,*pubkeystr; cJSON *retjson,*item,*array; + int32_t i; //,num=-1; struct iguana_info *coin; char params[256],*retstr,*pubkeystr; cJSON *retjson,*item,*array; if ( Notaries_num > 0 ) { for (i=0; i