summaryrefslogtreecommitdiff
path: root/src/sockets.cpp
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2012-09-02 08:30:54 -0400
committerAdam <Adam@anope.org>2012-09-02 08:30:54 -0400
commit1af64a9bbb150b9daae3944d6aae86864c271103 (patch)
treec24a1ac6793e997f83ac66810b611f88855fcd90 /src/sockets.cpp
parente3d5140dcc936ff411c438b7e3997104cb5f085a (diff)
Fix Windows
Diffstat (limited to 'src/sockets.cpp')
-rw-r--r--src/sockets.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/sockets.cpp b/src/sockets.cpp
index ebaf8f5a3..3d2df8dc9 100644
--- a/src/sockets.cpp
+++ b/src/sockets.cpp
@@ -14,10 +14,11 @@
#include "socketengine.h"
#include "logger.h"
+#ifndef _WIN32
#include <arpa/inet.h>
#include <errno.h>
-#include <unistd.h>
#include <fcntl.h>
+#endif
std::map<int, Socket *> SocketEngine::Sockets;
@@ -421,7 +422,7 @@ Socket::Socket(int sock, bool ipv6, int type) : Flags<SocketFlag>(SocketFlagStri
Socket::~Socket()
{
SocketEngine::DelSocket(this);
- close(this->Sock);
+ anope_close(this->Sock);
this->IO->Destroy();
}