diff options
-rw-r--r-- | CMakeLists.txt | 4 | ||||
-rw-r--r-- | handler.c | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 85527be..72d47a0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,10 +1,12 @@ cmake_minimum_required(VERSION 2.6) PROJECT(netifd C) -ADD_DEFINITIONS(-Os -Wall -Werror --std=gnu99 -Wmissing-declarations) +ADD_DEFINITIONS(-Os -Wall --std=gnu99 -Wmissing-declarations) SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") +INCLUDE_DIRECTORIES(${LIBNL_INCLUDE_DIRS}) + IF(APPLE) INCLUDE_DIRECTORIES(/opt/local/include) LINK_DIRECTORIES(/opt/local/lib) @@ -105,7 +105,7 @@ netifd_parse_script_handler(const char *name, script_dump_cb cb) tok = json_tokener_new(); obj = json_tokener_parse_ex(tok, start, len); - if (!is_error(obj)) { + if (!json_object_is_type(obj, json_type_null)) { netifd_init_script_handler(name, obj, cb); json_object_put(obj); json_tokener_free(tok); |