]> The Tcpdump Group git mirrors - tcpdump/blobdiff - tcpdump-stdinc.h
document SIGUSR1 in manual page
[tcpdump] / tcpdump-stdinc.h
index afcf803e8e0bee5e12b0639eae5a7827ecb5866c..32f8fc920b0111c079f2abf1c7bcd353493e1422 100644 (file)
@@ -39,6 +39,8 @@
 #ifndef tcpdump_stdinc_h
 #define tcpdump_stdinc_h
 
+#include <errno.h>
+
 #ifdef WIN32
 
 #include <stdint.h>
@@ -49,7 +51,6 @@
 #include <ctype.h>
 #include <time.h>
 #include <io.h>
-#include <errno.h>
 #include <fcntl.h>
 #include <sys/types.h>
 #include <net/netdb.h>  /* in wpcap's Win32/include */
@@ -234,11 +235,10 @@ typedef char* caddr_t;
  * Note: this also requires that padding be put into the structure,
  * at least for compilers where it's implemented as __attribute__((packed)).
  */
-#if defined(__GNUC__)
+#if !(defined(_MSC_VER) && defined(UNALIGNED))
+/* MSVC may have its own macro defined with the same name and purpose. */
 #undef UNALIGNED
 #define UNALIGNED      __attribute__((packed))
-#else
- /* MSVC may have its own macro defined with the same name and purpose. */
 #endif
 
 #if defined(WIN32) || defined(MSDOS)