patch-2.1.56 linux/net/ipv4/tcp_output.c

Next file: linux/net/ipv6/icmp.c
Previous file: linux/net/ipv4/arp.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.55/linux/net/ipv4/tcp_output.c linux/net/ipv4/tcp_output.c
@@ -605,10 +605,13 @@
 	memcpy(skb_put(skb, size2), ((char *) th2) + (th2->doff << 2), size2);
 	
 	/* Update sizes on original skb, both TCP and IP. */
-	skb->end_seq += size2;
+	skb->end_seq += buff->end_seq - buff->seq;
 	if (th2->urg) {
 		th1->urg = 1;
 		th1->urg_ptr = th2->urg_ptr + size1;
+	}
+	if (th2->fin) {
+		th1->fin = 1;
 	}
 
 	/* ... and off you go. */

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