Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs
[platform/upstream/kernel-adaptation-pc.git] / include / net / inet_hashtables.h
index 808fc5f..54be028 100644 (file)
@@ -379,10 +379,10 @@ static inline struct sock *__inet_lookup_skb(struct inet_hashinfo *hashinfo,
                                             const __be16 sport,
                                             const __be16 dport)
 {
-       struct sock *sk;
+       struct sock *sk = skb_steal_sock(skb);
        const struct iphdr *iph = ip_hdr(skb);
 
-       if (unlikely(sk = skb_steal_sock(skb)))
+       if (sk)
                return sk;
        else
                return __inet_lookup(dev_net(skb_dst(skb)->dev), hashinfo,