]> git.sur5r.net Git - freertos/blobdiff - FreeRTOS-Labs/Demo/FreeRTOS_IoT_Libraries/utilities/task_pool/WinPCap/pcap-stdinc.h
Add the Labs projects provided in the V10.2.1_191129 zip file.
[freertos] / FreeRTOS-Labs / Demo / FreeRTOS_IoT_Libraries / utilities / task_pool / WinPCap / pcap-stdinc.h
diff --git a/FreeRTOS-Labs/Demo/FreeRTOS_IoT_Libraries/utilities/task_pool/WinPCap/pcap-stdinc.h b/FreeRTOS-Labs/Demo/FreeRTOS_IoT_Libraries/utilities/task_pool/WinPCap/pcap-stdinc.h
new file mode 100644 (file)
index 0000000..cbd62d1
--- /dev/null
@@ -0,0 +1,93 @@
+/*\r
+ * Copyright (c) 2002 - 2005 NetGroup, Politecnico di Torino (Italy)\r
+ * Copyright (c) 2005 - 2009 CACE Technologies, Inc. Davis (California)\r
+ * All rights reserved.\r
+ *\r
+ * Redistribution and use in source and binary forms, with or without\r
+ * modification, are permitted provided that the following conditions\r
+ * are met:\r
+ *\r
+ * 1. Redistributions of source code must retain the above copyright\r
+ * notice, this list of conditions and the following disclaimer.\r
+ * 2. Redistributions in binary form must reproduce the above copyright\r
+ * notice, this list of conditions and the following disclaimer in the\r
+ * documentation and/or other materials provided with the distribution.\r
+ * 3. Neither the name of the Politecnico di Torino nor the names of its\r
+ * contributors may be used to endorse or promote products derived from\r
+ * this software without specific prior written permission.\r
+ *\r
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\r
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\r
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\r
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\r
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\r
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\r
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\r
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\r
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\r
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\r
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
+ *\r
+ * @(#) $Header: /tcpdump/master/libpcap/pcap-stdinc.h,v 1.10.2.1 2008-10-06 15:38:39 gianluca Exp $ (LBL)\r
+ */\r
+\r
+#define SIZEOF_CHAR 1\r
+#define SIZEOF_SHORT 2\r
+#define SIZEOF_INT 4\r
+#ifndef _MSC_EXTENSIONS\r
+#define SIZEOF_LONG_LONG 8\r
+#endif\r
+\r
+/*\r
+ * Avoids a compiler warning in case this was already defined      \r
+ * (someone defined _WINSOCKAPI_ when including 'windows.h', in order\r
+ * to prevent it from including 'winsock.h')\r
+ */\r
+#ifdef _WINSOCKAPI_\r
+#undef _WINSOCKAPI_\r
+#endif\r
+#include <winsock2.h>\r
+\r
+#include <fcntl.h>\r
+\r
+#include "bittypes.h"\r
+#include <time.h>\r
+#include <io.h>\r
+\r
+#ifndef __MINGW32__\r
+#include "IP6_misc.h"\r
+#endif\r
+\r
+#define caddr_t char*\r
+\r
+#if _MSC_VER < 1500\r
+#define snprintf _snprintf\r
+#define vsnprintf _vsnprintf\r
+#define strdup _strdup\r
+#endif\r
+\r
+#define inline __inline \r
+\r
+#ifdef __MINGW32__\r
+#include <stdint.h>\r
+#else /*__MINGW32__*/\r
+/* MSVC compiler */\r
+#ifndef _UINTPTR_T_DEFINED\r
+#ifdef  _WIN64\r
+typedef unsigned __int64    uintptr_t;\r
+#else\r
+typedef _W64 unsigned int   uintptr_t;\r
+#endif\r
+#define _UINTPTR_T_DEFINED\r
+#endif\r
+\r
+#ifndef _INTPTR_T_DEFINED\r
+#ifdef  _WIN64\r
+typedef __int64    intptr_t;\r
+#else\r
+typedef _W64 int   intptr_t;\r
+#endif\r
+#define _INTPTR_T_DEFINED\r
+#endif \r
+\r
+#endif /*__MINGW32__*/\r