vfs: fix uninitialized flags in splice_to_pipe()
authorMiklos Szeredi <mszeredi@redhat.com>
Thu, 16 Feb 2017 16:49:02 +0000 (17:49 +0100)
committerWilly Tarreau <w@1wt.eu>
Tue, 20 Jun 2017 12:04:20 +0000 (14:04 +0200)
commitfe75d1a6b0d2658a154e460cb00d390900c64e2a
tree04c7174c51d93dce744a6c3599ce92fd5e19eec9
parentc6cc07d404144f75945b6f96ede9510c1468f4b8
vfs: fix uninitialized flags in splice_to_pipe()

commit 5a81e6a171cdbd1fa8bc1fdd80c23d3d71816fac upstream.

Flags (PIPE_BUF_FLAG_PACKET, PIPE_BUF_FLAG_GIFT) could remain on the
unused part of the pipe ring buffer.  Previously splice_to_pipe() left
the flags value alone, which could result in incorrect behavior.

Uninitialized flags appears to have been there from the introduction of
the splice syscall.

Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Willy Tarreau <w@1wt.eu>
fs/splice.c