We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cc7b2fd commit 7c3df5eCopy full SHA for 7c3df5e
src/compat/compat.h
@@ -10,14 +10,17 @@
10
#include <config/bitcoin-config.h>
11
#endif
12
13
+// Windows defines FD_SETSIZE to 64 (see _fd_types.h in mingw-w64),
14
+// which is too small for our usage, but allows us to redefine it safely.
15
+// We redefine it to be 1024, to match glibc, see typesizes.h.
16
#ifdef WIN32
17
#ifdef FD_SETSIZE
-#undef FD_SETSIZE // prevent redefinition compiler warning
18
+#undef FD_SETSIZE
19
-#define FD_SETSIZE 1024 // max number of fds in fd_set
20
+#define FD_SETSIZE 1024
21
#include <winsock2.h>
22
#include <ws2tcpip.h>
-#include <stdint.h>
23
+#include <cstdint>
24
#else
25
#include <fcntl.h>
26
#include <sys/mman.h>
0 commit comments