Skip to content

Commit b940619

Browse files
committed
Merge #812: Fix create unsigned transaction fee bump
671b7a3 gui: fix create unsigned transaction fee bump (furszy) Pull request description: Fixes #810. Not much to explain; we were requiring the wallet to be unlocked for the unsigned transaction creation process. Fix this by moving the unlock wallet request to the signed transaction creation process. ACKs for top commit: pablomartin4btc: tACK 671b7a3 hebasto: ACK 671b7a3, tested on Ubuntu 24.04. Tree-SHA512: 5b9ec5a1b91c014c05c83c63daaa8ba33f9dc1bfa930442315a0913db710df17a1b6bb4ad39f1419a7054f37ebedb7ad52e1c5d3d2fb444b1676162e89a4efd2
2 parents ee94913 + 671b7a3 commit b940619

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

src/qt/walletmodel.cpp

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -529,12 +529,6 @@ bool WalletModel::bumpFee(uint256 hash, uint256& new_hash)
529529
return false;
530530
}
531531

532-
WalletModel::UnlockContext ctx(requestUnlock());
533-
if(!ctx.isValid())
534-
{
535-
return false;
536-
}
537-
538532
// Short-circuit if we are returning a bumped transaction PSBT to clipboard
539533
if (retval == QMessageBox::Save) {
540534
// "Create Unsigned" clicked
@@ -549,10 +543,15 @@ bool WalletModel::bumpFee(uint256 hash, uint256& new_hash)
549543
DataStream ssTx{};
550544
ssTx << psbtx;
551545
GUIUtil::setClipboard(EncodeBase64(ssTx.str()).c_str());
552-
Q_EMIT message(tr("PSBT copied"), tr("Copied to clipboard", "Fee-bump PSBT saved"), CClientUIInterface::MSG_INFORMATION);
546+
Q_EMIT message(tr("PSBT copied"), tr("Fee-bump PSBT copied to clipboard"), CClientUIInterface::MSG_INFORMATION | CClientUIInterface::MODAL);
553547
return true;
554548
}
555549

550+
WalletModel::UnlockContext ctx(requestUnlock());
551+
if (!ctx.isValid()) {
552+
return false;
553+
}
554+
556555
assert(!m_wallet->privateKeysDisabled() || wallet().hasExternalSigner());
557556

558557
// sign bumped transaction

0 commit comments

Comments
 (0)