Skip to content

Commit 12163bd

Browse files
committed
compat/net: Add io.h and SHUT_* macros
1 parent bc7e798 commit 12163bd

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

src/compat/net.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,12 @@
4545
#ifdef _WIN32
4646
#include <winsock2.h>
4747
#include <ws2tcpip.h> // for socklen_t
48+
#include <io.h> // for read, write
4849
typedef SOCKET fd_t;
4950
#define CLOSESOCKET closesocket
51+
#define SHUT_RD SD_RECEIVE
52+
#define SHUT_WR SD_SEND
53+
#define SHUT_RDWR SD_BOTH
5054
#else
5155
#include <arpa/inet.h> // for htonl, ntohl
5256
#include <netdb.h> // for getaddrinfo

0 commit comments

Comments
 (0)