From: Eric Leblond Date: Sun, 17 Mar 2019 20:11:25 +0000 (+0100) Subject: util-ebpf: better error handling X-Git-Tag: suricata-5.0.0-rc1~332 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3026e9a80db2450dfbe428b43e901fc5a24057fe;p=thirdparty%2Fsuricata.git util-ebpf: better error handling --- diff --git a/src/util-ebpf.c b/src/util-ebpf.c index b5c8ebf87c..4eeccbc3ff 100644 --- a/src/util-ebpf.c +++ b/src/util-ebpf.c @@ -130,9 +130,10 @@ static void EBPFDeleteKey(int fd, void *key) { int ret = bpf_map_delete_elem(fd, key); if (ret < 0) { - SCLogNotice("Unable to delete entry: %s (%d)", - strerror(errno), - errno); + SCLogWarning(SC_ERR_SYSCALL, + "Unable to delete entry: %s (%d)", + strerror(errno), + errno); } } @@ -172,8 +173,6 @@ int EBPFGetMapFDByName(const char *iface, const char *name) } } - /* Fallback by getting pinned maps ? */ - return -1; }