diff options
Diffstat (limited to 'plugins/FavContacts/src/csocket.cpp')
-rw-r--r-- | plugins/FavContacts/src/csocket.cpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/plugins/FavContacts/src/csocket.cpp b/plugins/FavContacts/src/csocket.cpp new file mode 100644 index 0000000000..8b31467c61 --- /dev/null +++ b/plugins/FavContacts/src/csocket.cpp @@ -0,0 +1,21 @@ +#include "headers.h"
+
+#include "csocket.h"
+
+int CSocket::Recv(char *buf, int count)
+{
+ return recv(m_socket, buf, count, 0);
+}
+
+int CSocket::Send(char *buf, int count)
+{
+ if (count < 0)
+ count = (int)strlen(buf);
+ return send(m_socket, buf, count, 0);
+}
+
+void CSocket::Close()
+{
+ shutdown(m_socket, SD_BOTH);
+ closesocket(m_socket);
+}
|