Skip to content

Commit 49221cf

Browse files
author
Miklos Szeredi
committed
fuse: reject internal errno
Don't allow userspace to report errors that could be kernel-internal. Reported-by: Anatoly Trosinenko <anatoly.trosinenko@gmail.com> Fixes: 334f485 ("[PATCH] FUSE - device functions") Cc: <stable@vger.kernel.org> # v2.6.14 Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
1 parent 80ef086 commit 49221cf

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎fs/fuse/dev.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1867,7 +1867,7 @@ static ssize_t fuse_dev_do_write(struct fuse_dev *fud,
18671867
}
18681868

18691869
err = -EINVAL;
1870-
if (oh.error <= -1000 || oh.error > 0)
1870+
if (oh.error <= -512 || oh.error > 0)
18711871
goto copy_finish;
18721872

18731873
spin_lock(&fpq->lock);

0 commit comments

Comments
 (0)