From 1b40260ae5b4e70b4b0baeb73d97345ee7da3b46 Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Fri, 16 Jun 2023 11:41:57 +0200 Subject: [PATCH] bpf: remove OpenBSD guards libpcap bpf functions are supported now. (cherry picked from commit 643e674cb216b3824fd5a3f4dd2d9f69847fc431) --- src/util-bpf.c | 4 ---- src/util-bpf.h | 3 --- 2 files changed, 7 deletions(-) diff --git a/src/util-bpf.c b/src/util-bpf.c index dd43201ad6..7f7149ef3c 100644 --- a/src/util-bpf.c +++ b/src/util-bpf.c @@ -51,8 +51,6 @@ void ConfSetBPFFilter( } } -#if !defined __OpenBSD__ - /** protect bpf filter build, as it is not thread safe */ static SCMutex bpf_set_filter_lock = SCMUTEX_INITIALIZER; @@ -97,5 +95,3 @@ int SCBPFCompile(int snaplen_arg, int linktype_arg, struct bpf_program *program, return (ret); } - -#endif /* Not __OpenBSD__ */ diff --git a/src/util-bpf.h b/src/util-bpf.h index 341c158453..8196077f8a 100644 --- a/src/util-bpf.h +++ b/src/util-bpf.h @@ -29,13 +29,10 @@ void ConfSetBPFFilter( ConfNode *if_root, ConfNode *if_default, const char *iface, const char **bpf_filter); -#if !defined __OpenBSD__ - int SCBPFCompile(int snaplen_arg, int linktype_arg, struct bpf_program *program, const char *buf, int optimize, uint32_t mask, char *errbuf, size_t errbuf_len); void SCBPFFree(struct bpf_program *program); -#endif /* Not __OpenBSD__ */ #endif /* __UTIL_BPF_H__ */ -- 2.47.2