Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
netfilter: ebtables: compat: un-break 32bit setsockopt when no rules …
…are present Unlike ip(6)tables ebtables only counts user-defined chains. The effect is that a 32bit ebtables binary on a 64bit kernel can do 'ebtables -N FOO' only after adding at least one rule, else the request fails with -EINVAL. This is a similar fix as done in 3f1e53a ("netfilter: ebtables: don't attempt to allocate 0-sized compat array"). Fixes: 7d7d7e0 ("netfilter: compat: reject huge allocation requests") Reported-by: Francesco Ruggeri <[email protected]> Signed-off-by: Florian Westphal <[email protected]> Signed-off-by: Pablo Neira Ayuso <[email protected]>
- Loading branch information