From a02cc7c96327fc19a7be1e2a0bb5d1fa13707e02 Mon Sep 17 00:00:00 2001 From: jl777 Date: Mon, 19 Feb 2018 21:17:19 +0200 Subject: [PATCH] Debug print --- iguana/exchanges/LP_prices.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/iguana/exchanges/LP_prices.c b/iguana/exchanges/LP_prices.c index 603faab5c..063942c76 100644 --- a/iguana/exchanges/LP_prices.c +++ b/iguana/exchanges/LP_prices.c @@ -512,7 +512,7 @@ char *LP_myprices() int32_t LP_mypriceset(int32_t *changedp,char *base,char *rel,double price) { - struct LP_priceinfo *basepp,*relpp; struct LP_pubkey_info *pubp; double minprice,maxprice; + struct LP_priceinfo *basepp=0,*relpp=0; struct LP_pubkey_info *pubp; double minprice,maxprice; *changedp = 0; //if ( strcmp("DEX",base) == 0 || strcmp("DEX",rel) == 0 ) printf("%s/%s setprice %.8f\n",base,rel,price); @@ -559,7 +559,9 @@ int32_t LP_mypriceset(int32_t *changedp,char *base,char *rel,double price) //pubp->matrix[relpp->ind][basepp->ind] = (1. / price); } return(0); - } else return(-1); + } + printf("base.%s rel.%s %p %p price %.8f error case\n",base!=0?base:"",rel!=0?rel:"",basepp,relpp,price); + return(-1); } double LP_price(char *base,char *rel)