]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: x_tables: rectify XT_FUNCTION_MAXNAMELEN usage
authorJan Engelhardt <jengelh@medozas.de>
Tue, 27 Apr 2010 13:34:34 +0000 (15:34 +0200)
committerPatrick McHardy <kaber@trash.net>
Tue, 27 Apr 2010 13:34:34 +0000 (15:34 +0200)
commitac399b26bbb7ead923cdb2734d6c4b359d4787c0
treeec3461cd593eaf65ffcd3fbb538c3976da1caa60
parent81a1770598485e3a6159db0d62fab4d5e417b0d2
netfilter: x_tables: rectify XT_FUNCTION_MAXNAMELEN usage

There has been quite a confusion in userspace about
XT_FUNCTION_MAXNAMELEN; because struct xt_entry_match used MAX-1,
userspace would have to do an awkward MAX-2 for maximum length
checking (due to '\0'). This patch adds a new define that matches the
definition of XT_TABLE_MAXNAMELEN - being the size of the actual
struct member, not one off.

Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Signed-off-by: Patrick McHardy <kaber@trash.net>
include/linux/netfilter/x_tables.h