diff options
author | 2015-10-12 10:54:35 -0700 | |
---|---|---|
committer | 2015-10-12 10:54:35 -0700 | |
commit | 378102f364d3fba88b8162df13d639d620e9272c (patch) | |
tree | 4d08ab65dc1e99d47c1b53fb7d7640711ea46cf6 /net/unix/af_unix.c | |
parent | Documentation: improve line discipline method descriptions (diff) | |
parent | Linux 4.3-rc5 (diff) | |
download | wireguard-linux-378102f364d3fba88b8162df13d639d620e9272c.tar.xz wireguard-linux-378102f364d3fba88b8162df13d639d620e9272c.zip |
Merge 4.3-rc5 into tty-next
We want the tty fixes and reverts in here as well so that people can
properly test and use it.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/unix/af_unix.c')
-rw-r--r-- | net/unix/af_unix.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c index 03ee4d359f6a..ef31b40ad550 100644 --- a/net/unix/af_unix.c +++ b/net/unix/af_unix.c @@ -2179,8 +2179,21 @@ unlock: if (UNIXCB(skb).fp) scm.fp = scm_fp_dup(UNIXCB(skb).fp); - sk_peek_offset_fwd(sk, chunk); + if (skip) { + sk_peek_offset_fwd(sk, chunk); + skip -= chunk; + } + if (UNIXCB(skb).fp) + break; + + last = skb; + last_len = skb->len; + unix_state_lock(sk); + skb = skb_peek_next(skb, &sk->sk_receive_queue); + if (skb) + goto again; + unix_state_unlock(sk); break; } } while (size); |