diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-03-21 16:57:10 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-03-21 16:57:27 +0100 |
commit | 310dc61ea3e2c9418af59575155889a891b9b6d0 (patch) | |
tree | 3d7e0cb6239a8510163910b3af44dda35bc3f5c6 /src/qt/paymentserver.cpp | |
parent | 4ad3b3c72c73d61e0a0cab541dca20acf651320d (diff) | |
parent | b7fbcc53d043eeb905652063ddc8ee39dad17dae (diff) |
Merge #12723: Qt5: Warning users about invalid-BIP21 URI bitcoin://
b7fbcc5 Qt: Warn users about invalid-BIP21 URI bitcoin:// (Alexey Ivanov)
Pull request description:
This change affects only Qt5 users, since Qt4 QUrl don't forces lower case for urls. Also bitcoin-qt builds against Qt4 on linux.
PR for #11645
Tree-SHA512: 6b8cb18b29dbd2754e190a662ed67274a7f0decc6adb00b7e1af107d5f8ea2845b668cf28d6ccf2f1d15e8ef212f5a76910810634a4c15e7fabd1dd2072e7232
Diffstat (limited to 'src/qt/paymentserver.cpp')
-rw-r--r-- | src/qt/paymentserver.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/qt/paymentserver.cpp b/src/qt/paymentserver.cpp index 92d7d72935..05d3d36a74 100644 --- a/src/qt/paymentserver.cpp +++ b/src/qt/paymentserver.cpp @@ -404,7 +404,12 @@ void PaymentServer::handleURIOrFile(const QString& s) return; } - if (s.startsWith(BITCOIN_IPC_PREFIX, Qt::CaseInsensitive)) // bitcoin: URI + if (s.startsWith("bitcoin://", Qt::CaseInsensitive)) + { + Q_EMIT message(tr("URI handling"), tr("'bitcoin://' is not a valid URI. Use 'bitcoin:' instead."), + CClientUIInterface::MSG_ERROR); + } + else if (s.startsWith(BITCOIN_IPC_PREFIX, Qt::CaseInsensitive)) // bitcoin: URI { #if QT_VERSION < 0x050000 QUrl uri(s); |