123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- #ifndef SOCKETS_H
- # define SOCKETS_H 1
- #define SOCKETS_1_0 0x100
- #define SOCKETS_1_1 0x101
- #define SOCKETS_2_0 0x200
- #define SOCKETS_2_1 0x201
- #define SOCKETS_2_2 0x202
- int gl_sockets_startup (int version)
- #if !WINDOWS_SOCKETS
- _GL_ATTRIBUTE_CONST
- #endif
- ;
- int gl_sockets_cleanup (void)
- #if !WINDOWS_SOCKETS
- _GL_ATTRIBUTE_CONST
- #endif
- ;
- #if WINDOWS_SOCKETS
- #include <sys/socket.h>
- #include "msvc-nothrow.h"
- static inline SOCKET
- gl_fd_to_handle (int fd)
- {
- return _get_osfhandle (fd);
- }
- #else
- #define gl_fd_to_handle(x) (x)
- #endif
- #endif
|