]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[NETFILTER]: expectation timeouts are compulsory
authorPhil Oester <kernel@linuxace.com>
Tue, 21 Jun 2005 21:02:42 +0000 (14:02 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 21 Jun 2005 21:02:42 +0000 (14:02 -0700)
Since expectation timeouts were made compulsory [1], there is no need to
check for them in ip_conntrack_expect_insert.

[1] https://lists.netfilter.org/pipermail/netfilter-devel/2005-January/018143.html

Signed-off-by: Phil Oester <kernel@linuxace.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/netfilter/ip_conntrack_core.c

index ffba0ad3c880bbc7a1bbbc4f04a73aba43e4320d..4b78ebeb66350e9616bf03d6468fc039b53716e6 100644 (file)
@@ -760,15 +760,11 @@ static void ip_conntrack_expect_insert(struct ip_conntrack_expect *exp)
        exp->master->expecting++;
        list_add(&exp->list, &ip_conntrack_expect_list);
 
-       if (exp->master->helper->timeout) {
-               init_timer(&exp->timeout);
-               exp->timeout.data = (unsigned long)exp;
-               exp->timeout.function = expectation_timed_out;
-               exp->timeout.expires
-                       = jiffies + exp->master->helper->timeout * HZ;
-               add_timer(&exp->timeout);
-       } else
-               exp->timeout.function = NULL;
+       init_timer(&exp->timeout);
+       exp->timeout.data = (unsigned long)exp;
+       exp->timeout.function = expectation_timed_out;
+       exp->timeout.expires = jiffies + exp->master->helper->timeout * HZ;
+       add_timer(&exp->timeout);
 
        CONNTRACK_STAT_INC(expect_create);
 }