From 9c850ba3cc818f06730bf153c2ffe23f7963047e Mon Sep 17 00:00:00 2001 From: jl777 Date: Mon, 4 Jul 2016 12:40:21 -0300 Subject: [PATCH] test --- basilisk/basilisk_MSG.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/basilisk/basilisk_MSG.c b/basilisk/basilisk_MSG.c index f19869f61..ce391cb02 100755 --- a/basilisk/basilisk_MSG.c +++ b/basilisk/basilisk_MSG.c @@ -200,6 +200,7 @@ int32_t basilisk_message_returned(uint8_t *data,int32_t maxlen,cJSON *item) { if ( (hexstr= jstr(msgobj,"data")) != 0 && (datalen= is_hexstr(hexstr,0)) > 0 ) { + datalen <<= 1; if ( datalen < maxlen ) { decode_hex(data,datalen,hexstr); @@ -231,7 +232,7 @@ int32_t basilisk_channelget(struct supernet_info *myinfo,bits256 hash,uint32_t c if ( (datalen= basilisk_message_returned(data,maxlen,item)) > 0 ) break; } - } else datalen = basilisk_message_returned(data,maxlen,retarray); + } else datalen = basilisk_message_returned(data,maxlen,retarray); free_json(retarray); } else printf("cant parse message\n"); free(retstr);