diff options
| author | Gavin Andresen <[email protected]> | 2011-12-20 08:52:22 -0800 |
|---|---|---|
| committer | Gavin Andresen <[email protected]> | 2011-12-20 08:52:22 -0800 |
| commit | 74f5435e104be76cd342a9a196ed4a10b8a7e248 (patch) | |
| tree | 254f76dfa15c36a359e661caa1b4cfd158e204f4 /src/protocol.cpp | |
| parent | Merge pull request #690 from runeksvendsen/qt-cmdline-options-parsing (diff) | |
| parent | Code cleanup: use ECDSA_size() instead of fixed 10,000 byte sig buffer, and e... (diff) | |
| download | discoin-74f5435e104be76cd342a9a196ed4a10b8a7e248.tar.xz discoin-74f5435e104be76cd342a9a196ed4a10b8a7e248.zip | |
Merge pull request #716 from gavinandresen/cleanup
Cleanups suggested by genjix
Diffstat (limited to 'src/protocol.cpp')
| -rw-r--r-- | src/protocol.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/protocol.cpp b/src/protocol.cpp index f46570e21..27efb8f29 100644 --- a/src/protocol.cpp +++ b/src/protocol.cpp @@ -223,7 +223,7 @@ bool CAddress::IsValid() const if (memcmp(pchReserved, pchIPv4+3, sizeof(pchIPv4)-3) == 0) return false; - return (ip != 0 && ip != INADDR_NONE && port != htons(USHRT_MAX)); + return (ip != 0 && ip != INADDR_NONE && port != htons(std::numeric_limits<unsigned short>::max())); } unsigned char CAddress::GetByte(int n) const |