summaryrefslogtreecommitdiff
path: root/src/net
diff options
context:
space:
mode:
Diffstat (limited to 'src/net')
-rw-r--r--src/net/sdltcpnet.cpp10
-rw-r--r--src/net/sdltcpnet.h4
2 files changed, 14 insertions, 0 deletions
diff --git a/src/net/sdltcpnet.cpp b/src/net/sdltcpnet.cpp
index ebe165125..36dac0fb2 100644
--- a/src/net/sdltcpnet.cpp
+++ b/src/net/sdltcpnet.cpp
@@ -139,6 +139,11 @@ int TcpNet::addSocket(const TcpNet::SocketSet set, const TcpNet::Socket sock)
return SDLNet_TCP_AddSocket(set, sock);
}
+int TcpNet::socketReady(const TcpNet::Socket sock)
+{
+ return SDLNet_SocketReady(sock);
+}
+
int TcpNet::checkSockets(const TcpNet::SocketSet set, const Uint32 timeout)
{
return SDLNet_CheckSockets(set, timeout);
@@ -158,3 +163,8 @@ void TcpNet::freeSocketSet(const TcpNet::SocketSet set)
{
SDLNet_FreeSocketSet(set);
}
+
+TcpNet::Socket TcpNet::accept(const TcpNet::Socket sock)
+{
+ return SDLNet_TCP_Accept(sock);
+}
diff --git a/src/net/sdltcpnet.h b/src/net/sdltcpnet.h
index 6b42ee1f7..fe3a7be66 100644
--- a/src/net/sdltcpnet.h
+++ b/src/net/sdltcpnet.h
@@ -49,6 +49,8 @@ namespace TcpNet
int addSocket(const TcpNet::SocketSet set, const TcpNet::Socket sock);
+ int socketReady(const TcpNet::Socket sock);
+
int checkSockets(const TcpNet::SocketSet set, const Uint32 timeout);
int recv(const TcpNet::Socket sock, void *const data, const int maxlen);
@@ -56,6 +58,8 @@ namespace TcpNet
int delSocket(const TcpNet::SocketSet set, const TcpNet::Socket sock);
void freeSocketSet(const TcpNet::SocketSet set);
+
+ TcpNet::Socket accept(const TcpNet::Socket sock);
} // namespace TcpNet
#endif // NET_SDLTCPNET_H