This commit is contained in:
jl777
2017-03-26 13:20:00 +03:00
parent 5de55e14aa
commit 7ed958da81

View File

@@ -357,8 +357,8 @@ int32_t notarizedtxid_height(char *txidstr,int32_t *kmdnotarized_heightp)
{ {
if ( (json= cJSON_Parse(jsonstr)) != 0 ) if ( (json= cJSON_Parse(jsonstr)) != 0 )
{ {
*kmdnotarized_heightp = jint(json,"notarized"); *kmdnotarized_heightp = jint(json,(char *)"notarized");
height = jint(json,"blocks"); height = jint(json,(char *)"blocks");
free_json(json); free_json(json);
} }
free(jsonstr); free(jsonstr);
@@ -368,8 +368,8 @@ int32_t notarizedtxid_height(char *txidstr,int32_t *kmdnotarized_heightp)
{ {
if ( (json= cJSON_Parse(jsonstr)) != 0 ) if ( (json= cJSON_Parse(jsonstr)) != 0 )
{ {
txid_confirmations = jint(json,"confirmations"); txid_confirmations = jint(json,(char *)"confirmations");
if ( confirmations > 0 && height > confirmations ) if ( txid_confirmations > 0 && height > txid_confirmations )
txid_height = height - txid_confirmations; txid_height = height - txid_confirmations;
free_json(json); free_json(json);
} }