|
@@ -1,11 +1,9 @@
|
|
#ifndef __COMMON_H__
|
|
#ifndef __COMMON_H__
|
|
#define __COMMON_H__
|
|
#define __COMMON_H__
|
|
|
|
|
|
-#include "config-host.h"
|
|
|
|
#include "slirp_config.h"
|
|
#include "slirp_config.h"
|
|
|
|
|
|
#ifdef _WIN32
|
|
#ifdef _WIN32
|
|
-# include <inttypes.h>
|
|
|
|
|
|
|
|
typedef char *caddr_t;
|
|
typedef char *caddr_t;
|
|
|
|
|
|
@@ -23,43 +21,31 @@ typedef char *caddr_t;
|
|
# endif
|
|
# endif
|
|
#endif
|
|
#endif
|
|
|
|
|
|
-#include <sys/types.h>
|
|
|
|
#ifdef HAVE_SYS_BITYPES_H
|
|
#ifdef HAVE_SYS_BITYPES_H
|
|
# include <sys/bitypes.h>
|
|
# include <sys/bitypes.h>
|
|
#endif
|
|
#endif
|
|
|
|
|
|
-#include <sys/time.h>
|
|
|
|
|
|
|
|
#ifdef HAVE_UNISTD_H
|
|
#ifdef HAVE_UNISTD_H
|
|
-# include <unistd.h>
|
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
#ifdef HAVE_STDLIB_H
|
|
#ifdef HAVE_STDLIB_H
|
|
-# include <stdlib.h>
|
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
-#include <stdio.h>
|
|
|
|
-#include <errno.h>
|
|
|
|
|
|
|
|
#ifndef HAVE_MEMMOVE
|
|
#ifndef HAVE_MEMMOVE
|
|
#define memmove(x, y, z) bcopy(y, x, z)
|
|
#define memmove(x, y, z) bcopy(y, x, z)
|
|
#endif
|
|
#endif
|
|
|
|
|
|
#if TIME_WITH_SYS_TIME
|
|
#if TIME_WITH_SYS_TIME
|
|
-# include <sys/time.h>
|
|
|
|
-# include <time.h>
|
|
|
|
#else
|
|
#else
|
|
# ifdef HAVE_SYS_TIME_H
|
|
# ifdef HAVE_SYS_TIME_H
|
|
-# include <sys/time.h>
|
|
|
|
# else
|
|
# else
|
|
-# include <time.h>
|
|
|
|
# endif
|
|
# endif
|
|
#endif
|
|
#endif
|
|
|
|
|
|
#ifdef HAVE_STRING_H
|
|
#ifdef HAVE_STRING_H
|
|
-# include <string.h>
|
|
|
|
#else
|
|
#else
|
|
-# include <strings.h>
|
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
#ifndef _WIN32
|
|
#ifndef _WIN32
|
|
@@ -82,11 +68,9 @@ void *malloc(size_t arg);
|
|
void free(void *ptr);
|
|
void free(void *ptr);
|
|
#endif
|
|
#endif
|
|
|
|
|
|
-#include <fcntl.h>
|
|
|
|
#ifndef NO_UNIX_SOCKETS
|
|
#ifndef NO_UNIX_SOCKETS
|
|
#include <sys/un.h>
|
|
#include <sys/un.h>
|
|
#endif
|
|
#endif
|
|
-#include <signal.h>
|
|
|
|
#ifdef HAVE_SYS_SIGNAL_H
|
|
#ifdef HAVE_SYS_SIGNAL_H
|
|
# include <sys/signal.h>
|
|
# include <sys/signal.h>
|
|
#endif
|
|
#endif
|
|
@@ -115,12 +99,10 @@ void free(void *ptr);
|
|
#endif
|
|
#endif
|
|
|
|
|
|
#ifdef __STDC__
|
|
#ifdef __STDC__
|
|
-#include <stdarg.h>
|
|
|
|
#else
|
|
#else
|
|
#include <varargs.h>
|
|
#include <varargs.h>
|
|
#endif
|
|
#endif
|
|
|
|
|
|
-#include <sys/stat.h>
|
|
|
|
|
|
|
|
/* Avoid conflicting with the libc insque() and remque(), which
|
|
/* Avoid conflicting with the libc insque() and remque(), which
|
|
have different prototypes. */
|
|
have different prototypes. */
|