Skip to content
Commit 6db40cf0 authored by Miklos Szeredi's avatar Miklos Szeredi Committed by Jens Axboe
Browse files

pipe: fix check in "set size" fcntl



As it stands this check compares the number of pages to the page size.
This makes no sense and makes the fcntl fail in almost any sane case.

Fix it by checking if nr_pages is not zero (it can become zero only if
arg is too big and round_pipe_size() overflows).

Signed-off-by: default avatarMiklos Szeredi <mszeredi@suse.cz>
Signed-off-by: default avatarJens Axboe <jaxboe@fusionio.com>
parent 1d862f41
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment