tipc: Optimize pointer dereferencing when receiving stream data
authorAllan Stephens <allan.stephens@windriver.com>
Tue, 15 Jul 2008 05:42:51 +0000 (22:42 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 15 Jul 2008 05:42:51 +0000 (22:42 -0700)
This patch eliminates an unnecessary pointer dereference when
accessing a stream-based socket's receive queue.

Signed-off-by: Allan Stephens <allan.stephens@windriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/socket.c

index 9c362c5759ba3fb8423cf7363f4b63a103eaa288..ddcb2a753aa6281ce2d10a397f9aa46083d2335f 100644 (file)
@@ -1133,7 +1133,7 @@ restart:
        /* Loop around if more data is required */
 
        if ((sz_copied < buf_len)    /* didn't get all requested data */
-           && (!skb_queue_empty(&sock->sk->sk_receive_queue) ||
+           && (!skb_queue_empty(&sk->sk_receive_queue) ||
                (flags & MSG_WAITALL))
                                     /* ... and more is ready or required */
            && (!(flags & MSG_PEEK)) /* ... and aren't just peeking at data */