Browse Source

Include stddef.h to use the standard offsetof()

src/utils/list.h ended up defining a local version of offsetof() due to
stddef.h not getting included. This resulted in unnecessary warnings
from ubsan related to "dereferencing" of a NULL pointer.

Signed-off-by: Jouni Malinen <j@w1.fi>
Jouni Malinen 9 years ago
parent
commit
bd47c80564
1 changed files with 1 additions and 0 deletions
  1. 1 0
      src/utils/includes.h

+ 1 - 0
src/utils/includes.h

@@ -17,6 +17,7 @@
 #include "build_config.h"
 
 #include <stdlib.h>
+#include <stddef.h>
 #include <stdio.h>
 #include <stdarg.h>
 #include <string.h>