patch-2.1.8 linux/net/core/sock.c

Next file: linux/net/ethernet/eth.c
Previous file: linux/net/core/skbuff.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.7/linux/net/core/sock.c linux/net/core/sock.c
@@ -192,6 +192,10 @@
 			return(0);
 
 		case SO_KEEPALIVE:
+			if (sk->protocol == IPPROTO_TCP)
+			{
+				tcp_set_keepalive(sk, valbool);
+			}
 			sk->keepopen = valbool;
 			return(0);
 
@@ -536,7 +540,7 @@
 void __release_sock(struct sock *sk)
 {
 #ifdef CONFIG_INET
-	if (!sk->prot || !sk->prot->rcv)
+	if (!sk->prot || !sk->backlog_rcv)
 		return;
 		
 	/* See if we have any packets built up. */
@@ -544,10 +548,7 @@
 	while (!skb_queue_empty(&sk->back_log)) {
 		struct sk_buff * skb = sk->back_log.next;
 		__skb_unlink(skb, &sk->back_log);
-		sk->prot->rcv(skb, skb->dev, (struct options*)skb->proto_priv,
-			      skb->saddr, skb->len, skb->daddr, 1,
-			      /* Only used for/by raw sockets. */
-			      (struct inet_protocol *)sk->pair); 
+		sk->backlog_rcv(sk, skb);
 	}
 	end_bh_atomic();
 #endif  

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