diff options
| author | Ingo Molnar <mingo@kernel.org> | 2017-08-26 09:20:01 +0200 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2017-08-26 09:20:01 +0200 |
| commit | 3cb9bc85029f2ceb7a5babadcab445c7cb861da8 (patch) | |
| tree | 6453e9ebb9ad3b3cab07ff31dc9a90ea9f7951bc /net/unix | |
| parent | f1a5b53570001b1bcbf890ac6c4be1db99f8cc28 (diff) | |
| parent | 413d63d71b222108d19703f3fd5cf9108652a730 (diff) | |
Merge branch 'x86/mm' into efi/core, to pick up dependencies
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'net/unix')
| -rw-r--r-- | net/unix/af_unix.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/net/unix/af_unix.c b/net/unix/af_unix.c index 7b52a380d710..be8982b4f8c0 100644 --- a/net/unix/af_unix.c +++ b/net/unix/af_unix.c @@ -2304,10 +2304,7 @@ static int unix_stream_read_generic(struct unix_stream_read_state *state, */ mutex_lock(&u->iolock); - if (flags & MSG_PEEK) - skip = sk_peek_offset(sk, flags); - else - skip = 0; + skip = max(sk_peek_offset(sk, flags), 0); do { int chunk; |
