From 8368edc12304bef82030d35105073341d2d0bfce Mon Sep 17 00:00:00 2001 From: Paolo Pisati Date: Mon, 17 Mar 2008 23:02:56 +0000 Subject: [PATCH] Don't cache ptr to nat rule in case of tablearg argument. Bug spotted by: Dyadchenko Mihail --- sys/netinet/ip_fw2.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sys/netinet/ip_fw2.c b/sys/netinet/ip_fw2.c index 67be4a9e0de2..a3347e55d77c 100644 --- a/sys/netinet/ip_fw2.c +++ b/sys/netinet/ip_fw2.c @@ -3297,7 +3297,8 @@ check_body: if (t == NULL) { retval = IP_FW_DENY; goto done; - } else + } + if (cmd->arg1 != IP_FW_TABLEARG) ((ipfw_insn_nat *)cmd)->nat = t; } retval = ipfw_nat_ptr(args, t, m);