Correct wrong source for lockTimeA when Bob waiting for P2SH-B. Spotted by tcallahan14. In lieu of PR #23

This commit is contained in:
catbref 2020-08-31 09:14:15 +01:00
parent 1ca5b864a9
commit 99315c7378

View File

@ -785,7 +785,7 @@ public class TradeBot {
byte[] redeemScriptBytes = BTCP2SH.buildScript(crossChainTradeData.partnerBitcoinPKH, crossChainTradeData.lockTimeB, crossChainTradeData.creatorBitcoinPKH, crossChainTradeData.hashOfSecretB);
String p2shAddress = BTC.getInstance().deriveP2shAddress(redeemScriptBytes);
int lockTimeA = tradeBotData.getLockTimeA();
int lockTimeA = crossChainTradeData.lockTimeA;
Long estimatedFee = BTC.getInstance().estimateFee(lockTimeA * 1000L);
if (estimatedFee == null) {
LOGGER.debug(() -> String.format("Couldn't estimate Bitcoin fees?"));