diff options
| author | Cory Fields <[email protected]> | 2016-08-04 16:37:49 -0400 |
|---|---|---|
| committer | Cory Fields <[email protected]> | 2016-08-04 16:41:39 -0400 |
| commit | 8945384bca00f74ba85c98a52925c254c49025a5 (patch) | |
| tree | c5479d77e5feb28ed75b53715073bcf3b46c1ffe /src/qt/optionsdialog.cpp | |
| parent | net: narrow include scope after moving to netaddress (diff) | |
| download | discoin-8945384bca00f74ba85c98a52925c254c49025a5.tar.xz discoin-8945384bca00f74ba85c98a52925c254c49025a5.zip | |
net: Have LookupNumeric return a CService directly
Also fix up a few small issues:
- Lookup with "badip:port" now sets the port to 0
- Don't allow assert to have side-effects
Diffstat (limited to 'src/qt/optionsdialog.cpp')
| -rw-r--r-- | src/qt/optionsdialog.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/qt/optionsdialog.cpp b/src/qt/optionsdialog.cpp index e419e4d9e..f73bb8706 100644 --- a/src/qt/optionsdialog.cpp +++ b/src/qt/optionsdialog.cpp @@ -327,8 +327,7 @@ QValidator::State ProxyAddressValidator::validate(QString &input, int &pos) cons { Q_UNUSED(pos); // Validate the proxy - CService serv; - LookupNumeric(input.toStdString().c_str(), serv, 9050); + CService serv(LookupNumeric(input.toStdString().c_str(), 9050)); proxyType addrProxy = proxyType(serv, true); if (addrProxy.IsValid()) return QValidator::Acceptable; |