aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/fuse/dev.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/fuse/dev.c b/fs/fuse/dev.c
index 63d2cf43b5e..6b8843d4ad8 100644
--- a/fs/fuse/dev.c
+++ b/fs/fuse/dev.c
@@ -739,7 +739,7 @@ static ssize_t fuse_dev_writev(struct file *file, const struct iovec *iov,
739 struct fuse_copy_state cs; 739 struct fuse_copy_state cs;
740 struct fuse_conn *fc = fuse_get_conn(file); 740 struct fuse_conn *fc = fuse_get_conn(file);
741 if (!fc) 741 if (!fc)
742 return -ENODEV; 742 return -EPERM;
743 743
744 fuse_copy_init(&cs, fc, 0, NULL, iov, nr_segs); 744 fuse_copy_init(&cs, fc, 0, NULL, iov, nr_segs);
745 if (nbytes < sizeof(struct fuse_out_header)) 745 if (nbytes < sizeof(struct fuse_out_header))
@@ -930,7 +930,7 @@ static int fuse_dev_fasync(int fd, struct file *file, int on)
930{ 930{
931 struct fuse_conn *fc = fuse_get_conn(file); 931 struct fuse_conn *fc = fuse_get_conn(file);
932 if (!fc) 932 if (!fc)
933 return -ENODEV; 933 return -EPERM;
934 934
935 /* No locking - fasync_helper does its own locking */ 935 /* No locking - fasync_helper does its own locking */
936 return fasync_helper(fd, file, on, &fc->fasync); 936 return fasync_helper(fd, file, on, &fc->fasync);