Skip to contentSkip to conversation

: expectation timeouts are compulsory

PATCH In review Patrick McHardy 1 participant 1 message Jun 20, 2005

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 4/7 : expectation timeouts are compulsory

[NETFILTER]: expectation timeouts are compulsory

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

---
commit 9b4be665b104791bd5605849391ed7123e14edd8
tree 61844cac98e0aedcc42238061e4f0e26a1c31102
parent 6f3e8460b395913e1f156c6e66e818c83afc4d25
author Phil Oester <[email protected]> Mon, 20 Jun 2005 18:50:05 committer Patrick McHardy <[email protected]> Mon, 20 Jun 2005 18:50:05

 net/ipv4/netfilter/ip_conntrack_core.c |   14 +++++---------
 1 files changed, 5 insertions(+), 9 deletions(-)
net/ipv4/netfilter/ip_conntrack_core.c +5 -9
@@ -760,15 +760,11 @@ static void ip_conntrack_expect_insert(s
 	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);
 }