diff options
author | Michal Rostecki <mrostecki@opensuse.org> | 2019-11-21 13:33:32 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2019-11-21 14:40:24 +0100 |
commit | 3ecea86f855dd964c95b0481c9010ae200e90560 (patch) | |
tree | e507223265617e35e0cd7b82e9933cfb7cb40f83 /src | |
parent | 3a7bdd02207f7ae6cd74af8c313d6d0f8f66f4be (diff) |
mnl: Fix -Wimplicit-function-declaration warnings
This change fixes the following warnings:
mnl.c: In function ‘mnl_nft_flowtable_add’:
mnl.c:1442:14: warning: implicit declaration of function ‘calloc’ [-Wimplicit-function-declaration]
dev_array = calloc(len, sizeof(char *));
^~~~~~
mnl.c:1442:14: warning: incompatible implicit declaration of built-in function ‘calloc’
mnl.c:1442:14: note: include ‘<stdlib.h>’ or provide a declaration of ‘calloc’
mnl.c:1449:2: warning: implicit declaration of function ‘free’ [-Wimplicit-function-declaration]
free(dev_array);
^~~~
mnl.c:1449:2: warning: incompatible implicit declaration of built-in function ‘free’
mnl.c:1449:2: note: include ‘<stdlib.h>’ or provide a declaration of ‘free’
Signed-off-by: Michal Rostecki <mrostecki@opensuse.org>
Acked-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'src')
-rw-r--r-- | src/mnl.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -30,6 +30,7 @@ #include <arpa/inet.h> #include <fcntl.h> #include <errno.h> +#include <stdlib.h> #include <utils.h> #include <nftables.h> |