diff --git a/iguana/exchanges/LP_commands.c b/iguana/exchanges/LP_commands.c index 39362b627..84e80801d 100644 --- a/iguana/exchanges/LP_commands.c +++ b/iguana/exchanges/LP_commands.c @@ -305,7 +305,7 @@ trust(pubkey, trust)\n\ return(LP_utxos(1,LP_mypeer,jstr(argjson,"coin"),jint(argjson,"lastn"))); else if ( strcmp(method,"utxo") == 0 ) { - printf("UTXO.%s\n",method); + //printf("UTXO.%s\n",method); if ( LP_utxoaddjson(1,LP_mypubsock,argjson) != 0 ) retstr = clonestr("{\"result\":\"success\",\"utxo\":\"received\"}"); else retstr = clonestr("{\"result\":\"couldnt add utxo\"}"); diff --git a/iguana/exchanges/LP_nativeDEX.c b/iguana/exchanges/LP_nativeDEX.c index d49fb01d7..670b32a38 100644 --- a/iguana/exchanges/LP_nativeDEX.c +++ b/iguana/exchanges/LP_nativeDEX.c @@ -154,7 +154,7 @@ char *LP_process_message(void *ctx,char *typestr,char *myipaddr,int32_t pubsock, if ( duplicate != 0 ) dup++; else uniq++; - printf("%s dup.%d (%u / %u) %.1f%% encrypted.%d recv.%u [%02x %02x] vs %02x %02x\n",typestr,duplicate,dup,dup+uniq,(double)100*dup/(dup+uniq),encrypted,crc32,ptr[0],ptr[1],crc32&0xff,(crc32>>8)&0xff); + printf("%s dup.%d (%u / %u) %.1f%% encrypted.%d recv.%u [%02x %02x] vs %02x %02x U.%d\n",typestr,duplicate,dup,dup+uniq,(double)100*dup/(dup+uniq),encrypted,crc32,ptr[0],ptr[1],crc32&0xff,(crc32>>8)&0xff,LP_mypeer != 0 ? LP_mypeer->numutxos : -1); if ( duplicate == 0 ) { LP_crc32find(&duplicate,i,crc32); diff --git a/iguana/exchanges/LP_utxos.c b/iguana/exchanges/LP_utxos.c index c1fbe9081..6a4ba2eed 100644 --- a/iguana/exchanges/LP_utxos.c +++ b/iguana/exchanges/LP_utxos.c @@ -602,6 +602,8 @@ struct LP_utxoinfo *LP_utxoadd(int32_t iambob,int32_t mypubsock,char *symbol,bit portable_mutex_unlock(&LP_utxomutex); if ( iambob != 0 ) { + if ( LP_mypeer != 0 ) + LP_mypeer->numutxos++; /*if ( mypubsock >= 0 ) { msg = jprint(LP_utxojson(utxo),1); @@ -611,10 +613,7 @@ struct LP_utxoinfo *LP_utxoadd(int32_t iambob,int32_t mypubsock,char *symbol,bit { LP_utxo_clientpublish(utxo); if ( LP_mypeer != 0 ) - { - LP_mypeer->numutxos++; utxo->T.lasttime = (uint32_t)time(NULL); - } } } return(utxo);