fixed MEM_STATIC already defined in Linux Kernel mode

This commit is contained in:
Yann Collet
2023-06-14 20:07:18 -07:00
parent 74c901bbed
commit d9645327b3
3 changed files with 4 additions and 1 deletions
+2
View File
@@ -90,6 +90,7 @@
* Updating the prefix is probably preferable, but requires a fairly large codemod,
* since this name is used everywhere.
*/
#ifndef MEM_STATIC /* already defined in Linux Kernel mem.h */
#if defined(__GNUC__)
# define MEM_STATIC static __inline UNUSED_ATTR
#elif defined (__cplusplus) || (defined (__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) /* C99 */)
@@ -99,6 +100,7 @@
#else
# define MEM_STATIC static /* this version may generate warnings for unused static functions; disable the relevant warning */
#endif
#endif
/* force no inlining */
#ifdef _MSC_VER