mirror of
https://github.com/Qortal/altcoinj.git
synced 2025-11-01 21:17:13 +00:00
When deserializing client payment channel state, if there was an existing close transaction, it was deserialized from wrong data.
This commit is contained in:
@@ -300,8 +300,10 @@ public class StoredPaymentChannelClientStates implements WalletExtension {
|
|||||||
ECKey.fromPrivate(storedState.getMyKey().toByteArray()),
|
ECKey.fromPrivate(storedState.getMyKey().toByteArray()),
|
||||||
Coin.valueOf(storedState.getValueToMe()),
|
Coin.valueOf(storedState.getValueToMe()),
|
||||||
Coin.valueOf(storedState.getRefundFees()), false);
|
Coin.valueOf(storedState.getRefundFees()), false);
|
||||||
if (storedState.hasCloseTransactionHash())
|
if (storedState.hasCloseTransactionHash()) {
|
||||||
channel.close = containingWallet.getTransaction(new Sha256Hash(storedState.toByteArray()));
|
Sha256Hash closeTxHash = new Sha256Hash(storedState.getCloseTransactionHash().toByteArray());
|
||||||
|
channel.close = containingWallet.getTransaction(closeTxHash);
|
||||||
|
}
|
||||||
putChannel(channel, false);
|
putChannel(channel, false);
|
||||||
}
|
}
|
||||||
} finally {
|
} finally {
|
||||||
|
|||||||
Reference in New Issue
Block a user