Skip to content

Commit 2c530ea

Browse files
committed
HTML escape address labels in more dialogs and notifications
1 parent 1770a97 commit 2c530ea

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/qt/sendcoinsdialog.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ void SendCoinsDialog::on_sendButton_clicked()
297297
{
298298
if(rcp.label.length() > 0) // label with address
299299
{
300-
recipientElement.append(tr("%1 to '%2'").arg(amount, rcp.label));
300+
recipientElement.append(tr("%1 to '%2'").arg(amount, GUIUtil::HtmlEscape(rcp.label)));
301301
recipientElement.append(QString(" (%1)").arg(address));
302302
}
303303
else // just address

src/qt/walletview.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ void WalletView::processNewTransaction(const QModelIndex& parent, int start, int
170170
QString type = ttm->index(start, TransactionTableModel::Type, parent).data().toString();
171171
QModelIndex index = ttm->index(start, 0, parent);
172172
QString address = ttm->data(index, TransactionTableModel::AddressRole).toString();
173-
QString label = ttm->data(index, TransactionTableModel::LabelRole).toString();
173+
QString label = GUIUtil::HtmlEscape(ttm->data(index, TransactionTableModel::LabelRole).toString());
174174

175175
Q_EMIT incomingTransaction(date, walletModel->getOptionsModel()->getDisplayUnit(), amount, type, address, label, GUIUtil::HtmlEscape(walletModel->getWalletName()));
176176
}

0 commit comments

Comments
 (0)