patch-2.1.111 linux/net/ipv4/ip_fw.c

Next file: linux/Documentation/Configure.help
Previous file: linux/net/ax25/ax25_subr.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.110/linux/net/ipv4/ip_fw.c linux/net/ipv4/ip_fw.c
@@ -510,7 +510,7 @@
 
 static inline void
 ip_fw_domatch(struct ip_fwkernel *f,
-	      const struct iphdr *ip, 
+	      struct iphdr *ip, 
 	      const char *rif,
 	      const ip_chainlabel label,
 	      struct sk_buff *skb,
@@ -522,6 +522,8 @@
 	if (f->ipfw.fw_flg & IP_FW_F_PRN) {
 		dump_packet(ip,rif,f,label,src_port,dst_port);
 	}
+	ip->tos = (ip->tos & f->ipfw.fw_tosand) ^ f->ipfw.fw_tosxor;
+
 /* This functionality is useless in stock 2.0.x series, but we don't
  * discard the mark thing altogether, to avoid breaking ipchains (and,
  * more importantly, the ipfwadm wrapper) --PR */


FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov