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/httpserver.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/httpserver.cpp')
| -rw-r--r-- | src/httpserver.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/httpserver.cpp b/src/httpserver.cpp index 2c5bc2c79..2bb4be564 100644 --- a/src/httpserver.cpp +++ b/src/httpserver.cpp @@ -619,7 +619,7 @@ CService HTTPRequest::GetPeer() const char* address = ""; uint16_t port = 0; evhttp_connection_get_peer(con, (char**)&address, &port); - LookupNumeric(address, peer, port); + peer = LookupNumeric(address, port); } return peer; } |