diff --git a/basilisk/basilisk.c b/basilisk/basilisk.c index 0e63d2163..b2697b8a3 100755 --- a/basilisk/basilisk.c +++ b/basilisk/basilisk.c @@ -191,8 +191,8 @@ int32_t basilisk_sendcmd(struct supernet_info *myinfo,char *destipaddr,char *typ continue; if ( (addr= iguana_peerslot(coin,calc_ipbits(destipaddr),0)) != 0 ) { - printf("RET [%d] to %s\n",datalen,addr->ipaddr); - return(iguana_queue_send(addr,delaymillis,&data[-(int32_t)sizeof(struct iguana_msghdr)],cmd,datalen)); + printf("RET [%d] to %s\n",datalen,addr->ipaddr); + return(iguana_queue_send(addr,delaymillis,&data[-(int32_t)sizeof(struct iguana_msghdr)],cmd,datalen)); } } printf("cant find (%s) to RET to\n",addr->ipaddr); diff --git a/iguana/iguana_peers.c b/iguana/iguana_peers.c index 2ed78c747..fa3625608 100755 --- a/iguana/iguana_peers.c +++ b/iguana/iguana_peers.c @@ -517,7 +517,7 @@ int32_t iguana_send(struct iguana_info *coin,struct iguana_peer *addr,uint8_t *s } } addr->totalsent += len; - if ( addr->msgcounts.verack == 0 ) + if ( 0 && addr->msgcounts.verack == 0 ) printf("verack.%d (%s) sent.%d bytes to %s\n",addr->msgcounts.verack,cmdstr,len,addr->ipaddr); return(len); } diff --git a/iguana/iguana_wallet.c b/iguana/iguana_wallet.c index 8fbc88afd..8fe08d229 100755 --- a/iguana/iguana_wallet.c +++ b/iguana/iguana_wallet.c @@ -1098,7 +1098,7 @@ double _max100(double val) cJSON *iguana_getinfo(struct supernet_info *myinfo,struct iguana_info *coin) { - cJSON *retjson = cJSON_CreateObject(); + int32_t i; struct iguana_peer *addr; cJSON *array,*retjson = cJSON_CreateObject(); if ( coin != 0 ) { jaddstr(retjson,"result","success"); @@ -1118,7 +1118,17 @@ cJSON *iguana_getinfo(struct supernet_info *myinfo,struct iguana_info *coin) jaddnum(retjson,"longestchain",coin->longestchain); jaddnum(retjson,"port",coin->chain->portp2p); if ( coin->peers != 0 ) + { + array = cJSON_CreateArray(); + for (i=0; ipeers->active[i]; + if ( addr->usock >= 0 && addr->supernet != 0 && addr->ipaddr[0] != 0 ) + jaddistr(array,addr->ipaddr); + } + jadd(retjson,"supernet",array); jaddnum(retjson,"connections",coin->peers->numranked); + } jaddnum(retjson,"difficulty",coin->blocks.hwmchain.PoW); jaddstr(retjson,"status",coin->statusstr); jaddstr(retjson,"coin",coin->symbol);