From 3a9b6817573d3e949b09a8d929b106df4e6fea5b Mon Sep 17 00:00:00 2001 From: jl777 Date: Sat, 22 Sep 2018 03:39:18 -1100 Subject: [PATCH] Test --- src/cc/dapps/oraclefeed.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/cc/dapps/oraclefeed.c b/src/cc/dapps/oraclefeed.c index fb32820e9..297b92a01 100644 --- a/src/cc/dapps/oraclefeed.c +++ b/src/cc/dapps/oraclefeed.c @@ -673,13 +673,13 @@ int32_t get_gatewaysinfo(char *refcoin,char *acname,char *depositaddr,int32_t *M char *oracle,*retstr,*name,*deposit; cJSON *retjson; if ( (retjson= get_komodocli(refcoin,&retstr,acname,"gatewaysinfo",bindtxidstr,"","","")) != 0 ) { - if ( (oracle= jstr(retjson,"oracletxid")) != 0 && strcmp(oracle,oraclestr) == 0 ) + if ( (oracle= jstr(retjson,"oracletxid")) != 0 && strcmp(oracle,oraclestr) == 0 && (deposit= jstr(retjson,"deposit")) != 0 ) { - if ( jstr(retjson,"coin") != 0 && strcmp(jstr(retjson,"coin"),coin) == 0 && jint(retjson,"N") >= 1 && (deposit= jstr(retjson,"deposit")) != 0 ) + strcpy(depositaddr,deposit); + if ( jstr(retjson,"coin") != 0 && strcmp(jstr(retjson,"coin"),coin) == 0 && jint(retjson,"N") >= 1 ) { *Mp = jint(retjson,"M"); *Np = jint(retjson,"N"); - strcpy(depositaddr,deposit); //printf("(%s)\n",jprint(retjson,0)); } else printf("coin.%s vs %s\n",jstr(retjson,"coin"),coin); } else printf("%s != %s\n",oracle,oraclestr);