Add some includes required by Apple clang.

Signed-off-by: Andrea Odetti <mariofutire@gmail.com>
This commit is contained in:
Andrea Odetti 2021-10-17 09:21:08 +01:00
parent 0d88767320
commit fff8fe91a9

View file

@ -2,10 +2,20 @@
#include "linux/network/uthernet2.h"
#include <unistd.h>
#include <sys/types.h>
#include <errno.h>
#include <sys/socket.h>
#include <arpa/inet.h>
#include <poll.h>
// fix SOCK_NONBLOCK for e.g. macOS
#ifndef SOCK_NONBLOCK
// DISCALIMER
// totally untested, use at your own risk
#include <fcntl.h>
#define SOCK_NONBLOCK O_NONBLOCK
#endif
#define MAX_RXLENGTH 1518
// #define U2_LOG_VERBOSE