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

Next file: linux/net/ipx/af_ipx.c
Previous file: linux/net/ipv4/tcp_input.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.76/linux/net/ipv4/tcp_output.c linux/net/ipv4/tcp_output.c
@@ -738,8 +738,8 @@
 	 *	Charge the sock_buff to newsk. 
 	 */
 	 
-	sk->rmem_alloc -= skb->truesize;
-	newsk->rmem_alloc += skb->truesize;
+	atomic_sub(skb->truesize, &sk->rmem_alloc);
+	atomic_add(skb->truesize, &newsk->rmem_alloc);
 	
 	skb_queue_tail(&sk->receive_queue,skb);
 	sk->ack_backlog++;

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this