From bf97128c7262f17a02fec41cdae75b472ba77f88 Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Tue, 3 Nov 2009 19:55:11 +0100 Subject: libxtables: hand argv to xtables_check_inverse In going to fix NF bug #611, "argv" is needed in xtables_check_inverse to set "optarg" to the right spot in case of an intrapositional negation. References: http://bugzilla.netfilter.org/show_bug.cgi?id=611 Signed-off-by: Jan Engelhardt --- extensions/libxt_physdev.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'extensions/libxt_physdev.c') diff --git a/extensions/libxt_physdev.c b/extensions/libxt_physdev.c index 74d311da..bd107669 100644 --- a/extensions/libxt_physdev.c +++ b/extensions/libxt_physdev.c @@ -43,7 +43,7 @@ physdev_parse(int c, char **argv, int invert, unsigned int *flags, case '1': if (*flags & XT_PHYSDEV_OP_IN) goto multiple_use; - xtables_check_inverse(optarg, &invert, &optind, 0); + xtables_check_inverse(optarg, &invert, &optind, 0, argv); xtables_parse_interface(argv[optind-1], info->physindev, (unsigned char *)info->in_mask); if (invert) @@ -55,7 +55,7 @@ physdev_parse(int c, char **argv, int invert, unsigned int *flags, case '2': if (*flags & XT_PHYSDEV_OP_OUT) goto multiple_use; - xtables_check_inverse(optarg, &invert, &optind, 0); + xtables_check_inverse(optarg, &invert, &optind, 0, argv); xtables_parse_interface(argv[optind-1], info->physoutdev, (unsigned char *)info->out_mask); if (invert) @@ -67,7 +67,7 @@ physdev_parse(int c, char **argv, int invert, unsigned int *flags, case '3': if (*flags & XT_PHYSDEV_OP_ISIN) goto multiple_use; - xtables_check_inverse(optarg, &invert, &optind, 0); + xtables_check_inverse(optarg, &invert, &optind, 0, argv); info->bitmask |= XT_PHYSDEV_OP_ISIN; if (invert) info->invert |= XT_PHYSDEV_OP_ISIN; @@ -77,7 +77,7 @@ physdev_parse(int c, char **argv, int invert, unsigned int *flags, case '4': if (*flags & XT_PHYSDEV_OP_ISOUT) goto multiple_use; - xtables_check_inverse(optarg, &invert, &optind, 0); + xtables_check_inverse(optarg, &invert, &optind, 0, argv); info->bitmask |= XT_PHYSDEV_OP_ISOUT; if (invert) info->invert |= XT_PHYSDEV_OP_ISOUT; @@ -87,7 +87,7 @@ physdev_parse(int c, char **argv, int invert, unsigned int *flags, case '5': if (*flags & XT_PHYSDEV_OP_BRIDGED) goto multiple_use; - xtables_check_inverse(optarg, &invert, &optind, 0); + xtables_check_inverse(optarg, &invert, &optind, 0, argv); if (invert) info->invert |= XT_PHYSDEV_OP_BRIDGED; *flags |= XT_PHYSDEV_OP_BRIDGED; -- cgit v1.2.3