]> The Tcpdump Group git mirrors - tcpdump/blobdiff - tcpdump-stdinc.h
From Peter Fales: don't assume "sprintf()" returns the number of
[tcpdump] / tcpdump-stdinc.h
index b5a9e9084e33f8117bbb54a4d446bfae9a99d794..7e5049da3b99734dfe9e069600bd25434f38731b 100644 (file)
  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
  * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
+ *
+ * @(#) $Header: /tcpdump/master/tcpdump/tcpdump-stdinc.h,v 1.3 2002-08-05 07:47:24 guy Exp $ (LBL)
+ */
+
+/*
+ * Include the appropriate OS header files on Windows and various flavors
+ * of UNIX, and also define some additional items and include various
+ * non-OS header files on Windows, and; this isolates most of the platform
+ * differences to this one file.
  */
 
 #ifdef WIN32
@@ -58,29 +67,26 @@ typedef char* caddr_t;
 #define O_RDONLY _O_RDONLY
 
 typedef short ino_t;
-#endif
+#endif /* __MINGW32__ */
 
-#else
+#else /* WIN32 */
 
 #include <ctype.h>
 #include <unistd.h>
 #include <netdb.h>
-#include <sys/socket.h>
 #include <sys/param.h>
-#include <sys/types.h>
+#include <sys/types.h>                 /* concession to AIX */
 #include <sys/time.h>
-#include <net/if.h>
+#include <sys/socket.h>
 #include <netinet/in.h>
-#include <sys/file.h>
-#include <sys/ioctl.h>
-#include <sys/uio.h>
 
-#ifdef HAVE_SYS_SOCKIO_H
-#include <sys/sockio.h>
+#ifdef TIME_WITH_SYS_TIME
+#include <time.h>
+#endif
+
 #include <arpa/inet.h>
-#endif /* HAVE_SYS_SOCKIO_H */
 
-#endif
+#endif /* WIN32 */
 
 #ifdef INET6
 #include "ip6.h"