aboutsummaryrefslogtreecommitdiff
path: root/src/netbase.cpp
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2012-05-09 03:48:14 +0200
committerPieter Wuille <pieter.wuille@gmail.com>2012-05-09 03:48:30 +0200
commitf621326c24791be14aa61221f7e35530378b84d8 (patch)
tree447995abd684e0fa74804aa5df76bd14417250c3 /src/netbase.cpp
parent781fc2c8c0972764e61dafda6fa82b7fd2a198f2 (diff)
Clean up warnings
* Use -Wall -Wextra -Wformat -Wformat-security -Wno-unused-parameters * Remove xCXXFLAGS usage in makefile.unix * Fix several recent and older sign-compare warnings
Diffstat (limited to 'src/netbase.cpp')
-rw-r--r--src/netbase.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/netbase.cpp b/src/netbase.cpp
index 4fe3fb61da..48709dc5c6 100644
--- a/src/netbase.cpp
+++ b/src/netbase.cpp
@@ -208,9 +208,9 @@ bool static Socks5(string strDest, int port, SOCKET& hSocket)
}
char pszSocks5Init[] = "\5\1\0";
char *pszSocks5 = pszSocks5Init;
- int nSize = sizeof(pszSocks5Init);
+ ssize_t nSize = sizeof(pszSocks5Init);
- int ret = send(hSocket, pszSocks5, nSize, MSG_NOSIGNAL);
+ ssize_t ret = send(hSocket, pszSocks5, nSize, MSG_NOSIGNAL);
if (ret != nSize)
{
closesocket(hSocket);
@@ -234,7 +234,7 @@ bool static Socks5(string strDest, int port, SOCKET& hSocket)
strSocks5 += static_cast<char>((port >> 8) & 0xFF);
strSocks5 += static_cast<char>((port >> 0) & 0xFF);
ret = send(hSocket, strSocks5.c_str(), strSocks5.size(), MSG_NOSIGNAL);
- if (ret != strSocks5.size())
+ if (ret != (ssize_t)strSocks5.size())
{
closesocket(hSocket);
return error("Error sending to proxy");