|
@ -17,7 +17,6 @@ |
|
|
// LP_remember.c
|
|
|
// LP_remember.c
|
|
|
// marketmaker
|
|
|
// marketmaker
|
|
|
//
|
|
|
//
|
|
|
|
|
|
|
|
|
void basilisk_dontforget_userdata(char *userdataname,FILE *fp,uint8_t *script,int32_t scriptlen) |
|
|
void basilisk_dontforget_userdata(char *userdataname,FILE *fp,uint8_t *script,int32_t scriptlen) |
|
|
{ |
|
|
{ |
|
|
int32_t i; char scriptstr[513]; |
|
|
int32_t i; char scriptstr[513]; |
|
@ -70,6 +69,13 @@ void basilisk_dontforget(struct basilisk_swap *swap,struct basilisk_rawtx *rawtx |
|
|
fprintf(fp,",\"bobtomic\":\"%s\"",swap->I.bobtomic); |
|
|
fprintf(fp,",\"bobtomic\":\"%s\"",swap->I.bobtomic); |
|
|
if ( swap->I.etomicsrc[0] != 0 ) |
|
|
if ( swap->I.etomicsrc[0] != 0 ) |
|
|
fprintf(fp,",\"etomicsrc\":\"%s\"",swap->I.etomicsrc); |
|
|
fprintf(fp,",\"etomicsrc\":\"%s\"",swap->I.etomicsrc); |
|
|
|
|
|
if (swap->bobdeposit.I.ethTxid[0] != 0) { |
|
|
|
|
|
fprintf(fp,",\"bobDepositEthTx\":\"%s\"", swap->bobdeposit.I.ethTxid); |
|
|
|
|
|
} |
|
|
|
|
|
if (swap->bobpayment.I.ethTxid[0] != 0) { |
|
|
|
|
|
fprintf(fp,",\"bobPaymentEthTx\":\"%s\"", swap->bobpayment.I.ethTxid); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
fprintf(fp,",\"alicecoin\":\"%s\"",swap->I.alicestr); |
|
|
fprintf(fp,",\"alicecoin\":\"%s\"",swap->I.alicestr); |
|
|
if ( swap->I.alicetomic[0] != 0 ) |
|
|
if ( swap->I.alicetomic[0] != 0 ) |
|
|
fprintf(fp,",\"alicetomic\":\"%s\"",swap->I.alicetomic); |
|
|
fprintf(fp,",\"alicetomic\":\"%s\"",swap->I.alicetomic); |
|
@ -128,6 +134,7 @@ void basilisk_dontforget(struct basilisk_swap *swap,struct basilisk_rawtx *rawtx |
|
|
init_hexbytes_noT(secretBn256str,swap->I.secretBn256,32); |
|
|
init_hexbytes_noT(secretBn256str,swap->I.secretBn256,32); |
|
|
fprintf(fp,",\"secretBn256\":\"%s\"",secretBn256str); |
|
|
fprintf(fp,",\"secretBn256\":\"%s\"",secretBn256str); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
for (i=0; i<2; i++) |
|
|
for (i=0; i<2; i++) |
|
|
if ( bits256_nonz(swap->I.myprivs[i]) != 0 ) |
|
|
if ( bits256_nonz(swap->I.myprivs[i]) != 0 ) |
|
|
fprintf(fp,",\"myprivs%d\":\"%s\"",i,bits256_str(str,swap->I.myprivs[i])); |
|
|
fprintf(fp,",\"myprivs%d\":\"%s\"",i,bits256_str(str,swap->I.myprivs[i])); |
|
@ -845,6 +852,31 @@ int32_t LP_swap_load(struct LP_swap_remember *rswap,int32_t forceflag) |
|
|
free_json(txobj); |
|
|
free_json(txobj); |
|
|
continue; |
|
|
continue; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (jstr(txobj,"etomicsrc") != 0) { |
|
|
|
|
|
strcpy(rswap->etomicsrc,jstr(txobj,"etomicsrc")); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (jstr(txobj,"etomicdest") != 0) { |
|
|
|
|
|
strcpy(rswap->etomicdest,jstr(txobj,"etomicdest")); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (jstr(txobj,"bobDepositEthTx") != 0) { |
|
|
|
|
|
strcpy(rswap->bobDepositEthTx, jstr(txobj,"bobDepositEthTx")); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (jstr(txobj,"bobPaymentEthTx") != 0) { |
|
|
|
|
|
strcpy(rswap->bobPaymentEthTx, jstr(txobj,"bobPaymentEthTx")); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (jstr(txobj,"bobtomic") != 0) { |
|
|
|
|
|
strcpy(rswap->bobtomic, jstr(txobj,"bobtomic")); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (jstr(txobj,"alicetomic") != 0) { |
|
|
|
|
|
strcpy(rswap->alicetomic, jstr(txobj,"alicetomic")); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
rswap->txids[i] = txid; |
|
|
rswap->txids[i] = txid; |
|
|
if ( jstr(txobj,"Apayment") != 0 ) |
|
|
if ( jstr(txobj,"Apayment") != 0 ) |
|
|
safecopy(rswap->alicepaymentaddr,jstr(txobj,"Apayment"),sizeof(rswap->alicepaymentaddr)); |
|
|
safecopy(rswap->alicepaymentaddr,jstr(txobj,"Apayment"),sizeof(rswap->alicepaymentaddr)); |
|
@ -916,6 +948,7 @@ int32_t LP_swap_load(struct LP_swap_remember *rswap,int32_t forceflag) |
|
|
//printf("%s %s %.8f\n",txnames[i],bits256_str(str,txid),dstr(value));
|
|
|
//printf("%s %s %.8f\n",txnames[i],bits256_str(str,txid),dstr(value));
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
free_json(txobj); |
|
|
free_json(txobj); |
|
|
} //else printf("no symbol\n");
|
|
|
} //else printf("no symbol\n");
|
|
|
free(fstr); |
|
|
free(fstr); |
|
@ -1019,24 +1052,8 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti |
|
|
srcAdest = srcBdest = destAdest = destBdest = 0; |
|
|
srcAdest = srcBdest = destAdest = destBdest = 0; |
|
|
alice = LP_coinfind(rswap.alicecoin); |
|
|
alice = LP_coinfind(rswap.alicecoin); |
|
|
bob = LP_coinfind(rswap.bobcoin); |
|
|
bob = LP_coinfind(rswap.bobcoin); |
|
|
if ( alice != 0 ) |
|
|
|
|
|
strcpy(etomicdest,alice->smartaddr); |
|
|
|
|
|
else etomicdest[0] = 0; |
|
|
|
|
|
if ( bob != 0 ) |
|
|
|
|
|
strcpy(etomicsrc,bob->smartaddr); |
|
|
|
|
|
else etomicsrc[0] = 0; |
|
|
|
|
|
LP_etomicsymbol(bobstr,bobtomic,rswap.src); |
|
|
LP_etomicsymbol(bobstr,bobtomic,rswap.src); |
|
|
if ( bobtomic[0] != 0 ) |
|
|
|
|
|
{ |
|
|
|
|
|
if ( (coin= LP_coinfind(rswap.src)) != 0 ) |
|
|
|
|
|
strcpy(etomicsrc,coin->smartaddr); |
|
|
|
|
|
} |
|
|
|
|
|
LP_etomicsymbol(alicestr,alicetomic,rswap.dest); |
|
|
LP_etomicsymbol(alicestr,alicetomic,rswap.dest); |
|
|
if ( alicetomic[0] != 0 ) |
|
|
|
|
|
{ |
|
|
|
|
|
if ( (coin= LP_coinfind(rswap.dest)) != 0 ) |
|
|
|
|
|
strcpy(etomicdest,coin->smartaddr); |
|
|
|
|
|
} |
|
|
|
|
|
if ( rswap.bobcoin[0] == 0 || rswap.alicecoin[0] == 0 || strcmp(rswap.bobcoin,bobstr) != 0 || strcmp(rswap.alicecoin,alicestr) != 0 ) |
|
|
if ( rswap.bobcoin[0] == 0 || rswap.alicecoin[0] == 0 || strcmp(rswap.bobcoin,bobstr) != 0 || strcmp(rswap.alicecoin,alicestr) != 0 ) |
|
|
{ |
|
|
{ |
|
|
//printf("legacy r%u-q%u DB SWAPS.(%u %u) %llu files BOB.(%s) Alice.(%s) src.(%s) dest.(%s)\n",requestid,quoteid,rswap.requestid,rswap.quoteid,(long long)rswap.aliceid,rswap.bobcoin,rswap.alicecoin,rswap.src,rswap.dest);
|
|
|
//printf("legacy r%u-q%u DB SWAPS.(%u %u) %llu files BOB.(%s) Alice.(%s) src.(%s) dest.(%s)\n",requestid,quoteid,rswap.requestid,rswap.quoteid,(long long)rswap.aliceid,rswap.bobcoin,rswap.alicecoin,rswap.src,rswap.dest);
|
|
@ -1194,7 +1211,10 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti |
|
|
rev.bytes[j] = rswap.myprivs[0].bytes[31 - j]; |
|
|
rev.bytes[j] = rswap.myprivs[0].bytes[31 - j]; |
|
|
if ( (rswap.txbytes[BASILISK_ALICESPEND]= basilisk_swap_bobtxspend(&signedtxid,rswap.Btxfee,"alicespend",rswap.bobcoin,bob->wiftaddr,bob->taddr,bob->pubtype,bob->p2shtype,bob->isPoS,bob->wiftype,ctx,rswap.myprivs[0],0,redeemscript,redeemlen,userdata,len,rswap.txids[BASILISK_BOBPAYMENT],0,0,rswap.pubkey33,1,rswap.expiration,&rswap.values[BASILISK_ALICESPEND],0,0,rswap.bobpaymentaddr,1,bob->zcash)) != 0 ) |
|
|
if ( (rswap.txbytes[BASILISK_ALICESPEND]= basilisk_swap_bobtxspend(&signedtxid,rswap.Btxfee,"alicespend",rswap.bobcoin,bob->wiftaddr,bob->taddr,bob->pubtype,bob->p2shtype,bob->isPoS,bob->wiftype,ctx,rswap.myprivs[0],0,redeemscript,redeemlen,userdata,len,rswap.txids[BASILISK_BOBPAYMENT],0,0,rswap.pubkey33,1,rswap.expiration,&rswap.values[BASILISK_ALICESPEND],0,0,rswap.bobpaymentaddr,1,bob->zcash)) != 0 ) |
|
|
{ |
|
|
{ |
|
|
//printf("alicespend.(%s)\n",rswap.txbytes[BASILISK_ALICESPEND]);
|
|
|
if (rswap.bobtomic[0] != 0) { |
|
|
|
|
|
char *aliceSpendEthTxId = LP_etomicalice_spends_bob_payment(&rswap); |
|
|
|
|
|
free(aliceSpendEthTxId); |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
LP_txbytes_update("alicespend",rswap.bobcoin,rswap.txbytes[BASILISK_ALICESPEND],&rswap.txids[BASILISK_ALICESPEND],&rswap.paymentspent,&rswap.sentflags[BASILISK_ALICESPEND]); |
|
|
LP_txbytes_update("alicespend",rswap.bobcoin,rswap.txbytes[BASILISK_ALICESPEND],&rswap.txids[BASILISK_ALICESPEND],&rswap.paymentspent,&rswap.sentflags[BASILISK_ALICESPEND]); |
|
@ -1220,8 +1240,13 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti |
|
|
if ( redeemlen > 0 ) |
|
|
if ( redeemlen > 0 ) |
|
|
{ |
|
|
{ |
|
|
len = basilisk_swapuserdata(userdata,zero,1,rswap.myprivs[0],redeemscript,redeemlen); |
|
|
len = basilisk_swapuserdata(userdata,zero,1,rswap.myprivs[0],redeemscript,redeemlen); |
|
|
if ( (rswap.txbytes[BASILISK_ALICECLAIM]= basilisk_swap_bobtxspend(&signedtxid,rswap.Btxfee,"aliceclaim",rswap.bobcoin,bob->wiftaddr,bob->taddr,bob->pubtype,bob->p2shtype,bob->isPoS,bob->wiftype,ctx,rswap.myprivs[0],0,redeemscript,redeemlen,userdata,len,rswap.txids[BASILISK_BOBDEPOSIT],0,0,rswap.pubkey33,0,claimtime,&rswap.values[BASILISK_ALICECLAIM],0,0,rswap.bobdepositaddr,1,bob->zcash)) != 0 ) |
|
|
if ( (rswap.txbytes[BASILISK_ALICECLAIM]= basilisk_swap_bobtxspend(&signedtxid,rswap.Btxfee,"aliceclaim",rswap.bobcoin,bob->wiftaddr,bob->taddr,bob->pubtype,bob->p2shtype,bob->isPoS,bob->wiftype,ctx,rswap.myprivs[0],0,redeemscript,redeemlen,userdata,len,rswap.txids[BASILISK_BOBDEPOSIT],0,0,rswap.pubkey33,0,claimtime,&rswap.values[BASILISK_ALICECLAIM],0,0,rswap.bobdepositaddr,1,bob->zcash)) != 0 ) { |
|
|
printf("claimtime.%u aliceclaim.(%s)\n",claimtime,rswap.txbytes[BASILISK_ALICECLAIM]); |
|
|
printf("claimtime.%u aliceclaim.(%s)\n", claimtime, rswap.txbytes[BASILISK_ALICECLAIM]); |
|
|
|
|
|
if (rswap.bobtomic[0] != 0) { |
|
|
|
|
|
char *aliceClaimsEthTxId = LP_etomicalice_claims_bob_deposit(&rswap); |
|
|
|
|
|
free(aliceClaimsEthTxId); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
LP_txbytes_update("aliceclaim",rswap.bobcoin,rswap.txbytes[BASILISK_ALICECLAIM],&rswap.txids[BASILISK_ALICECLAIM],&rswap.depositspent,&rswap.sentflags[BASILISK_ALICECLAIM]); |
|
|
LP_txbytes_update("aliceclaim",rswap.bobcoin,rswap.txbytes[BASILISK_ALICECLAIM],&rswap.txids[BASILISK_ALICECLAIM],&rswap.depositspent,&rswap.sentflags[BASILISK_ALICECLAIM]); |
|
|
} |
|
|
} |
|
@ -1241,8 +1266,13 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti |
|
|
rswap.privBn = basilisk_swap_privBn_extract(&rswap.txids[BASILISK_BOBREFUND],rswap.bobcoin,rswap.txids[BASILISK_BOBDEPOSIT],rswap.privBn); |
|
|
rswap.privBn = basilisk_swap_privBn_extract(&rswap.txids[BASILISK_BOBREFUND],rswap.bobcoin,rswap.txids[BASILISK_BOBDEPOSIT],rswap.privBn); |
|
|
if ( bits256_nonz(rswap.txids[BASILISK_ALICEPAYMENT]) != 0 && bits256_nonz(rswap.privAm) != 0 && bits256_nonz(rswap.privBn) != 0 ) |
|
|
if ( bits256_nonz(rswap.txids[BASILISK_ALICEPAYMENT]) != 0 && bits256_nonz(rswap.privAm) != 0 && bits256_nonz(rswap.privBn) != 0 ) |
|
|
{ |
|
|
{ |
|
|
if ( (rswap.txbytes[BASILISK_ALICERECLAIM]= basilisk_swap_Aspend("alicereclaim",rswap.alicecoin,rswap.Atxfee,alice->wiftaddr,alice->taddr,alice->pubtype,alice->p2shtype,alice->isPoS,alice->wiftype,ctx,rswap.privAm,rswap.privBn,rswap.txids[BASILISK_ALICEPAYMENT],0,rswap.pubkey33,rswap.expiration,&rswap.values[BASILISK_ALICERECLAIM],rswap.alicepaymentaddr,alice->zcash)) != 0 ) |
|
|
if ( (rswap.txbytes[BASILISK_ALICERECLAIM]= basilisk_swap_Aspend("alicereclaim",rswap.alicecoin,rswap.Atxfee,alice->wiftaddr,alice->taddr,alice->pubtype,alice->p2shtype,alice->isPoS,alice->wiftype,ctx,rswap.privAm,rswap.privBn,rswap.txids[BASILISK_ALICEPAYMENT],0,rswap.pubkey33,rswap.expiration,&rswap.values[BASILISK_ALICERECLAIM],rswap.alicepaymentaddr,alice->zcash)) != 0 ) { |
|
|
printf("alicereclaim.(%s)\n",rswap.txbytes[BASILISK_ALICERECLAIM]); |
|
|
printf("alicereclaim.(%s)\n", rswap.txbytes[BASILISK_ALICERECLAIM]); |
|
|
|
|
|
if (rswap.alicetomic[0] != 0) { |
|
|
|
|
|
char *aliceReclaimEthTx = LP_etomicalice_reclaims_payment(&rswap); |
|
|
|
|
|
free(aliceReclaimEthTx); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
LP_txbytes_update("alicereclaim",rswap.alicecoin,rswap.txbytes[BASILISK_ALICERECLAIM],&rswap.txids[BASILISK_ALICERECLAIM],&rswap.Apaymentspent,&rswap.sentflags[BASILISK_ALICERECLAIM]); |
|
|
LP_txbytes_update("alicereclaim",rswap.alicecoin,rswap.txbytes[BASILISK_ALICERECLAIM],&rswap.txids[BASILISK_ALICERECLAIM],&rswap.Apaymentspent,&rswap.sentflags[BASILISK_ALICERECLAIM]); |
|
|
} |
|
|
} |
|
@ -1274,6 +1304,10 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti |
|
|
{ |
|
|
{ |
|
|
if ( (rswap.txbytes[BASILISK_BOBSPEND]= basilisk_swap_Aspend("bobspend",rswap.alicecoin,rswap.Atxfee,alice->wiftaddr,alice->taddr,alice->pubtype,alice->p2shtype,alice->isPoS,alice->wiftype,ctx,rswap.privAm,rswap.privBn,rswap.txids[BASILISK_ALICEPAYMENT],0,rswap.pubkey33,rswap.expiration,&rswap.values[BASILISK_BOBSPEND],rswap.alicepaymentaddr,alice->zcash)) != 0 ) |
|
|
if ( (rswap.txbytes[BASILISK_BOBSPEND]= basilisk_swap_Aspend("bobspend",rswap.alicecoin,rswap.Atxfee,alice->wiftaddr,alice->taddr,alice->pubtype,alice->p2shtype,alice->isPoS,alice->wiftype,ctx,rswap.privAm,rswap.privBn,rswap.txids[BASILISK_ALICEPAYMENT],0,rswap.pubkey33,rswap.expiration,&rswap.values[BASILISK_BOBSPEND],rswap.alicepaymentaddr,alice->zcash)) != 0 ) |
|
|
{ |
|
|
{ |
|
|
|
|
|
if (rswap.alicetomic[0] != 0) { |
|
|
|
|
|
char *bobSpendEthTx = LP_etomicbob_spends_alice_payment(&rswap); |
|
|
|
|
|
free(bobSpendEthTx); |
|
|
|
|
|
} |
|
|
//printf("bobspend.(%s)\n",rswap.txbytes[BASILISK_BOBSPEND]);
|
|
|
//printf("bobspend.(%s)\n",rswap.txbytes[BASILISK_BOBSPEND]);
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
@ -1299,6 +1333,10 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti |
|
|
len = basilisk_swapuserdata(userdata,zero,1,rswap.myprivs[1],redeemscript,redeemlen); |
|
|
len = basilisk_swapuserdata(userdata,zero,1,rswap.myprivs[1],redeemscript,redeemlen); |
|
|
if ( (rswap.txbytes[BASILISK_BOBRECLAIM]= basilisk_swap_bobtxspend(&signedtxid,rswap.Btxfee,"bobreclaim",rswap.bobcoin,bob->wiftaddr,bob->taddr,bob->pubtype,bob->p2shtype,bob->isPoS,bob->wiftype,ctx,rswap.myprivs[1],0,redeemscript,redeemlen,userdata,len,rswap.txids[BASILISK_BOBPAYMENT],0,0,rswap.pubkey33,0,claimtime,&rswap.values[BASILISK_BOBRECLAIM],0,0,rswap.bobpaymentaddr,1,bob->zcash)) != 0 ) |
|
|
if ( (rswap.txbytes[BASILISK_BOBRECLAIM]= basilisk_swap_bobtxspend(&signedtxid,rswap.Btxfee,"bobreclaim",rswap.bobcoin,bob->wiftaddr,bob->taddr,bob->pubtype,bob->p2shtype,bob->isPoS,bob->wiftype,ctx,rswap.myprivs[1],0,redeemscript,redeemlen,userdata,len,rswap.txids[BASILISK_BOBPAYMENT],0,0,rswap.pubkey33,0,claimtime,&rswap.values[BASILISK_BOBRECLAIM],0,0,rswap.bobpaymentaddr,1,bob->zcash)) != 0 ) |
|
|
{ |
|
|
{ |
|
|
|
|
|
if (rswap.bobtomic[0] != 0) { |
|
|
|
|
|
char *bobReclaimEthTx = LP_etomicbob_reclaims_payment(&rswap); |
|
|
|
|
|
free(bobReclaimEthTx); |
|
|
|
|
|
} |
|
|
//int32_t z;
|
|
|
//int32_t z;
|
|
|
//for (z=0; z<20; z++)
|
|
|
//for (z=0; z<20; z++)
|
|
|
// printf("%02x",rswap.secretAm[z]);
|
|
|
// printf("%02x",rswap.secretAm[z]);
|
|
@ -1333,6 +1371,10 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti |
|
|
len = basilisk_swapuserdata(userdata,rswap.privBn,0,rswap.myprivs[0],redeemscript,redeemlen); |
|
|
len = basilisk_swapuserdata(userdata,rswap.privBn,0,rswap.myprivs[0],redeemscript,redeemlen); |
|
|
if ( (rswap.txbytes[BASILISK_BOBREFUND]= basilisk_swap_bobtxspend(&signedtxid,rswap.Btxfee,"bobrefund",rswap.bobcoin,bob->wiftaddr,bob->taddr,bob->pubtype,bob->p2shtype,bob->isPoS,bob->wiftype,ctx,rswap.myprivs[0],0,redeemscript,redeemlen,userdata,len,rswap.txids[BASILISK_BOBDEPOSIT],0,0,rswap.pubkey33,1,rswap.expiration,&rswap.values[BASILISK_BOBREFUND],0,0,rswap.bobdepositaddr,1,bob->zcash)) != 0 ) |
|
|
if ( (rswap.txbytes[BASILISK_BOBREFUND]= basilisk_swap_bobtxspend(&signedtxid,rswap.Btxfee,"bobrefund",rswap.bobcoin,bob->wiftaddr,bob->taddr,bob->pubtype,bob->p2shtype,bob->isPoS,bob->wiftype,ctx,rswap.myprivs[0],0,redeemscript,redeemlen,userdata,len,rswap.txids[BASILISK_BOBDEPOSIT],0,0,rswap.pubkey33,1,rswap.expiration,&rswap.values[BASILISK_BOBREFUND],0,0,rswap.bobdepositaddr,1,bob->zcash)) != 0 ) |
|
|
{ |
|
|
{ |
|
|
|
|
|
if (rswap.bobtomic[0] != 0) { |
|
|
|
|
|
char *bobRefundsEthTx = LP_etomicbob_refunds_deposit(&rswap); |
|
|
|
|
|
free(bobRefundsEthTx); |
|
|
|
|
|
} |
|
|
//printf("pubB1.(%s) bobrefund.(%s)\n",bits256_str(str,rswap.pubB1),rswap.txbytes[BASILISK_BOBREFUND]);
|
|
|
//printf("pubB1.(%s) bobrefund.(%s)\n",bits256_str(str,rswap.pubB1),rswap.txbytes[BASILISK_BOBREFUND]);
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|