hostfs: hostfs_open: Reset open flags upon each retry

...otherwise we might end up with an incorrect mode mode.

Signed-off-by: Richard Weinberger <richard@nod.at>
This commit is contained in:
Richard Weinberger 2015-03-04 22:39:48 +01:00
parent 112a5da717
commit a9d1958b4b
1 changed files with 2 additions and 0 deletions

View File

@ -315,6 +315,8 @@ static int hostfs_open(struct inode *ino, struct file *file)
mode |= HOSTFS_I(ino)->mode;
retry:
r = w = 0;
if (mode & FMODE_READ)
r = 1;
if (mode & FMODE_WRITE)