]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
lib: cleanup
authorMarek Vavruša <marek.vavrusa@nic.cz>
Tue, 6 Oct 2015 16:44:41 +0000 (18:44 +0200)
committerMarek Vavruša <marek.vavrusa@nic.cz>
Tue, 6 Oct 2015 16:44:41 +0000 (18:44 +0200)
contrib/ccan/compiler/compiler.h
modules/cachectl/cachectl.c

index e0c8dec8673a91087544fab51e73efa4aef9c3f0..bce4f25a122612d7f26f8e846564747a01836b3b 100644 (file)
 #define WARN_UNUSED_RESULT
 #endif
 #endif
-
-#ifndef NON_NULL
-#if HAVE_ATTRIBUTE_NONNULL
-/**
- * NON_NULL - nonnull attribute specifies that some function parameters should be non-null pointers.
- */
-#define NON_NULL(...) __attribute__((nonnull(__VA_ARGS__)))
-#else
-#define NON_NULL(...)
-#endif
-#endif
-
 #endif /* CCAN_COMPILER_H */
index 5aeb3b61c9abd8934908a5c1e336a40fa4346e34..695f6f0b52f6b68df0dad152ac8d2def4877f3c1 100644 (file)
@@ -28,7 +28,6 @@
 #include <time.h>
 #include <libknot/descriptor.h>
 #include <ccan/json/json.h>
-#include <ccan/compiler/compiler.h>
 
 #include "daemon/engine.h"
 #include "lib/module.h"
@@ -44,7 +43,7 @@
 typedef int (*cache_cb_t)(struct kr_cache_txn *txn, namedb_iter_t *it, namedb_val_t *key, void *baton);
 
 /** @internal Prefix walk. */
-NON_NULL(1,2) static int cache_prefixed(struct engine *engine, const char *args, unsigned txn_flags, cache_cb_t cb, void *baton)
+static int cache_prefixed(struct engine *engine, const char *args, unsigned txn_flags, cache_cb_t cb, void *baton)
 {
        /* Decode parameters */
        uint8_t namespace = 'R';