jl777 7 years ago
parent
commit
f2cd2e6ce2
  1. 6
      iguana/exchanges/LP_transaction.c

6
iguana/exchanges/LP_transaction.c

@ -746,8 +746,6 @@ char *basilisk_swap_bobtxspend(bits256 *signedtxidp,uint64_t txfee,char *name,ch
{ {
char *rawtxbytes=0,*signedtx=0,str[65],tmpaddr[64],hexstr[999],wifstr[128],_destaddr[64]; uint8_t spendscript[512],addrtype,rmd160[20]; cJSON *txobj,*vins,*obj,*vouts,*item,*privkeys; int32_t completed,spendlen,n,ignore_cltverr=1; struct vin_info V[8]; uint32_t timestamp,locktime = 0,sequenceid = 0xffffffff * finalseqid; bits256 txid; uint64_t value=0,change = 0; struct iguana_msgtx msgtx; struct iguana_info *coin; char *rawtxbytes=0,*signedtx=0,str[65],tmpaddr[64],hexstr[999],wifstr[128],_destaddr[64]; uint8_t spendscript[512],addrtype,rmd160[20]; cJSON *txobj,*vins,*obj,*vouts,*item,*privkeys; int32_t completed,spendlen,n,ignore_cltverr=1; struct vin_info V[8]; uint32_t timestamp,locktime = 0,sequenceid = 0xffffffff * finalseqid; bits256 txid; uint64_t value=0,change = 0; struct iguana_msgtx msgtx; struct iguana_info *coin;
LP_mark_spent(symbol,utxotxid,utxovout); LP_mark_spent(symbol,utxotxid,utxovout);
if ( txfee > 0 && txfee < LP_MIN_TXFEE )
txfee = LP_MIN_TXFEE;
*destamountp = 0; *destamountp = 0;
memset(signedtxidp,0,sizeof(*signedtxidp)); memset(signedtxidp,0,sizeof(*signedtxidp));
if ( finalseqid == 0 ) if ( finalseqid == 0 )
@ -758,6 +756,8 @@ char *basilisk_swap_bobtxspend(bits256 *signedtxidp,uint64_t txfee,char *name,ch
value = 0; value = 0;
if ( (coin= LP_coinfind(symbol)) != 0 ) if ( (coin= LP_coinfind(symbol)) != 0 )
{ {
if ( txfee > 0 && txfee < coin->txfee )
txfee = coin->txfee;
#ifndef BASILISK_DISABLESENDTX #ifndef BASILISK_DISABLESENDTX
if ( (txobj= LP_gettx(symbol,utxotxid,0)) != 0 ) if ( (txobj= LP_gettx(symbol,utxotxid,0)) != 0 )
{ {
@ -776,6 +776,8 @@ char *basilisk_swap_bobtxspend(bits256 *signedtxidp,uint64_t txfee,char *name,ch
} }
#endif #endif
} }
if ( txfee > 0 && txfee < LP_MIN_TXFEE )
txfee = LP_MIN_TXFEE;
if ( satoshis != 0 ) if ( satoshis != 0 )
{ {
if ( value < satoshis+txfee ) if ( value < satoshis+txfee )

Loading…
Cancel
Save