diff options
author | Linus Torvalds | 2017-10-28 08:27:46 -0700 |
---|---|---|
committer | Linus Torvalds | 2017-10-28 08:27:46 -0700 |
commit | a9af9835d31122b6354a44f99f74731f714233d2 (patch) | |
tree | 0ad69d0ab5d32985dd5f62309630282578662599 /fs | |
parent | 11224e1fc40a6556dc285573ea93dd522f8c563f (diff) | |
parent | c6cdd51404b7ac12dd95173ddfc548c59ecf037f (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse
Pull fuse fix from Miklos Szeredi:
"This fixes a longstanding bug, which can be triggered by interrupting
a directory reading syscall"
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse:
fuse: fix READDIRPLUS skipping an entry
Diffstat (limited to 'fs')
-rw-r--r-- | fs/fuse/dir.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c index 622081b97426..24967382a7b1 100644 --- a/fs/fuse/dir.c +++ b/fs/fuse/dir.c @@ -1308,7 +1308,8 @@ static int parse_dirplusfile(char *buf, size_t nbytes, struct file *file, */ over = !dir_emit(ctx, dirent->name, dirent->namelen, dirent->ino, dirent->type); - ctx->pos = dirent->off; + if (!over) + ctx->pos = dirent->off; } buf += reclen; |