Created
May 9, 2020 16:14
-
-
Save rw-r-r-0644/29c1658d0e1691ecd8d02d516b22fdda to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#pragma once | |
#include <wut.h> | |
#include <stdint.h> | |
#include <sys/time.h> | |
#include <sys/types.h> | |
#include <sys/socket.h> | |
#include <netinet/in.h> | |
#include <arpa/inet.h> | |
#include <unistd.h> | |
#warning "nsysnet/socket.h is deprecated; please use standard socket headers instead." | |
#ifdef __cplusplus | |
extern "C" { | |
#endif | |
extern int __wut_last_nsysnet_result; | |
#define NSN_EAGAIN 6 | |
#define NSN_EWOULDBLOCK 6 | |
__attribute__ ((deprecated)) | |
static inline void | |
socket_lib_init() | |
{ | |
} | |
__attribute__ ((deprecated)) | |
static inline void | |
socket_lib_finish() | |
{ | |
} | |
__attribute__ ((deprecated)) | |
static inline int | |
socketclose(int sockfd) | |
{ | |
return close(sockfd); | |
} | |
__attribute__ ((deprecated)) | |
static inline int socketlasterr() | |
{ | |
return __wut_last_nsysnet_result; | |
} | |
#ifdef __cplusplus | |
} | |
#endif | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment