From d08ae9402429bfca69d72c7a7d99975aa356539f Mon Sep 17 00:00:00 2001 From: sinanmohd Date: Mon, 8 Jul 2024 06:05:08 +0530 Subject: bpf/filter: init --- cmd/main.go | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'cmd') diff --git a/cmd/main.go b/cmd/main.go index 5c58d44..dc456ce 100644 --- a/cmd/main.go +++ b/cmd/main.go @@ -13,6 +13,7 @@ import ( "sinanmohd.com/redq/db" "sinanmohd.com/redq/dns" "sinanmohd.com/redq/bpf/usage" + "sinanmohd.com/redq/bpf/filter" ) func main() { @@ -37,6 +38,10 @@ func main() { if err != nil { os.Exit(0) } + f, err := filter.New(iface, queries, ctx) + if err != nil { + os.Exit(0) + } u, err := usage.New(iface) if err != nil { os.Exit(0) @@ -47,6 +52,7 @@ func main() { go func() { <-sigs usage.Close(u, queries, ctx) + filter.Close(f) api.Close(a) os.Exit(0) }() -- cgit v1.2.3