From b2dbe1f042f4c997f2477c6c842fd06e6451e88a Mon Sep 17 00:00:00 2001 From: jl777 Date: Sun, 22 May 2016 16:26:08 -0500 Subject: [PATCH] test --- iguana/swaps/iguana_BTCswap.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/iguana/swaps/iguana_BTCswap.c b/iguana/swaps/iguana_BTCswap.c index ad5109f81..fb429870b 100755 --- a/iguana/swaps/iguana_BTCswap.c +++ b/iguana/swaps/iguana_BTCswap.c @@ -441,14 +441,14 @@ int32_t instantdex_pubkeyargs(struct supernet_info *myinfo,struct bitcoin_swapin } n++; } - if ( (swap->otherhavestate & INSTANTDEX_ORDERSTATE_HAVEOTHERFEE) == 0 ) + if ( (swap->otherhavestate & INSTANTDEX_ORDERSTATE_HAVEOTHERFEE) == 0 && swap->myfee != 0 ) { jaddbits256(newjson,"feetxid",swap->myfee->txid); jaddstr(newjson,"feetx",swap->myfee->txbytes); } if ( instantdex_isbob(swap) != 0 ) { - if ( (swap->otherhavestate & INSTANTDEX_ORDERSTATE_HAVEALTPAYMENT) == 0 ) + if ( (swap->otherhavestate & INSTANTDEX_ORDERSTATE_HAVEALTPAYMENT) == 0 && swap->altpayment != 0 ) { jaddbits256(newjson,"altpaymenttxid",swap->altpayment->txid); jaddstr(newjson,"altpayment",swap->altpayment->txbytes); @@ -456,12 +456,12 @@ int32_t instantdex_pubkeyargs(struct supernet_info *myinfo,struct bitcoin_swapin } else { - if ( (swap->otherhavestate & INSTANTDEX_ORDERSTATE_HAVEDEPOSIT) == 0 ) + if ( (swap->otherhavestate & INSTANTDEX_ORDERSTATE_HAVEDEPOSIT) == 0 && swap->deposit != 0 ) { jaddbits256(newjson,"deposittxid",swap->deposit->txid); jaddstr(newjson,"deposit",swap->deposit->txbytes); } - else if ( (swap->otherhavestate & INSTANTDEX_ORDERSTATE_HAVEPAYMENT) == 0 ) + else if ( (swap->otherhavestate & INSTANTDEX_ORDERSTATE_HAVEPAYMENT) == 0 && swap->payment != 0 ) { jaddbits256(newjson,"paymenttxid",swap->payment->txid); jaddstr(newjson,"payment",swap->payment->txbytes);