]> git.tdb.fi Git - libs/net.git/commitdiff
Fix some compilation problems
authorMikko Rasa <tdb@tdb.fi>
Mon, 8 Oct 2012 20:37:44 +0000 (23:37 +0300)
committerMikko Rasa <tdb@tdb.fi>
Mon, 8 Oct 2012 20:37:44 +0000 (23:37 +0300)
source/net/resolve.cpp
source/net/socket.cpp

index e8aad664d3cb5c722f032874352c60c15a5309e9..8f5c97b9baa25f6fdd2d32ce74929260772789b9 100644 (file)
@@ -19,7 +19,7 @@ SockAddr *resolve(const string &host, const string &serv, Family family)
 {
        const char *chost = (host.empty() ? 0 : host.c_str());
        const char *cserv = (serv.empty() ? 0 : serv.c_str());
-       unsigned flags = 0;
+       int flags = 0;
        if(host=="*")
        {
                flags = AI_PASSIVE;
index 5af2b4f507e34de1a3527e1c9b99b5693441eae7..75919777e6cb0c256d3a9dea1bf0ded6bd3587b4 100644 (file)
@@ -1,5 +1,6 @@
 #ifndef WIN32
 #include <cerrno>
+#include <unistd.h>
 #include <fcntl.h>
 #include <sys/socket.h>
 #endif