summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2020-01-17 08:42:02 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2020-01-17 08:42:02 -0800
commitab7541c3addd344939e76d0636da0048ce24f2db (patch)
tree38dd8aa76af46e47354d7a3c4fc64834c6c9bd54 /fs
parent07d5ac6a12546fd23619ea60b211654efa55db86 (diff)
parent7df1e988c723a066754090b22d047c3225342152 (diff)
downloadlinux-stable-ab7541c3addd344939e76d0636da0048ce24f2db.tar.gz
linux-stable-ab7541c3addd344939e76d0636da0048ce24f2db.tar.bz2
linux-stable-ab7541c3addd344939e76d0636da0048ce24f2db.zip
Merge tag 'fuse-fixes-5.5-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse
Pull fuse fix from Miklos Szeredi: "Fix a regression in the last release affecting the ftp module of the gvfs filesystem" * tag 'fuse-fixes-5.5-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse: fuse: fix fuse_send_readpages() in the syncronous read case
Diffstat (limited to 'fs')
-rw-r--r--fs/fuse/file.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/fuse/file.c b/fs/fuse/file.c
index a63d779eac10..ce715380143c 100644
--- a/fs/fuse/file.c
+++ b/fs/fuse/file.c
@@ -882,6 +882,7 @@ static void fuse_send_readpages(struct fuse_io_args *ia, struct file *file)
struct fuse_args_pages *ap = &ia->ap;
loff_t pos = page_offset(ap->pages[0]);
size_t count = ap->num_pages << PAGE_SHIFT;
+ ssize_t res;
int err;
ap->args.out_pages = true;
@@ -896,7 +897,8 @@ static void fuse_send_readpages(struct fuse_io_args *ia, struct file *file)
if (!err)
return;
} else {
- err = fuse_simple_request(fc, &ap->args);
+ res = fuse_simple_request(fc, &ap->args);
+ err = res < 0 ? res : 0;
}
fuse_readpages_end(fc, &ap->args, err);
}