From: Felix Fietkau Date: Sun, 25 Feb 2018 15:23:07 +0000 (+0100) Subject: kernel: fix crash in flow offload code when cleaning up unregistered hooks X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=1ac14d312fc8042ab75abcac4decdb47a77c05f0;p=openwrt%2Fstaging%2Fansuel.git kernel: fix crash in flow offload code when cleaning up unregistered hooks Signed-off-by: Felix Fietkau --- diff --git a/target/linux/generic/hack-4.14/650-netfilter-add-xt_OFFLOAD-target.patch b/target/linux/generic/hack-4.14/650-netfilter-add-xt_OFFLOAD-target.patch index e2279fce65..40f89d4d91 100644 --- a/target/linux/generic/hack-4.14/650-netfilter-add-xt_OFFLOAD-target.patch +++ b/target/linux/generic/hack-4.14/650-netfilter-add-xt_OFFLOAD-target.patch @@ -216,7 +216,7 @@ Signed-off-by: Felix Fietkau + +restart: + hlist_for_each_entry(hook, &hooks, list) { -+ if (hook->used) ++ if (hook->used || !hook->registered) + continue; + + hlist_del(&hook->list);