patch-2.1.91 linux/net/ipv4/ip_masq_autofw.c
Next file: linux/net/ipv4/ip_masq_mod.c
Previous file: linux/net/ipv4/ip_masq.c
Back to the patch index
Back to the overall index
- Lines: 24
- Date:
Mon Mar 23 16:48:25 1998
- Orig file:
v2.1.90/linux/net/ipv4/ip_masq_autofw.c
- Orig date:
Wed Dec 10 09:45:16 1997
diff -u --recursive --new-file v2.1.90/linux/net/ipv4/ip_masq_autofw.c linux/net/ipv4/ip_masq_autofw.c
@@ -119,10 +119,8 @@
{
if (af->flags & IP_AUTOFW_USETIME)
{
- if (af->timer.expires)
- del_timer(&af->timer);
- af->timer.expires=jiffies+IP_AUTOFW_EXPIRE;
- add_timer(&af->timer);
+ mod_timer(&af->timer,
+ jiffies+IP_AUTOFW_EXPIRE);
}
af->flags|=IP_AUTOFW_ACTIVE;
af->lastcontact=where;
@@ -139,9 +137,7 @@
af=ip_autofw_check_range(where, port,protocol);
if (af)
{
- del_timer(&af->timer);
- af->timer.expires=jiffies+IP_AUTOFW_EXPIRE;
- add_timer(&af->timer);
+ mod_timer(&af->timer, jiffies+IP_AUTOFW_EXPIRE);
}
}
#endif
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov