author: Linus Torvalds <torvalds@linux-foundation.org> 2019-07-19 10:42:02 -0700
committer: Linus Torvalds <torvalds@linux-foundation.org> 2019-07-19 10:42:02 -0700
commit: 933a90bf4f3505f8ec83bda21a3c7d70d7c2b426
parent: 5f4fc6d440d77a2cf74fe4ea56955674ac7e35e7
Commit Summary:
Diffstat:
1 file changed, 1 insertion, 0 deletions
diff --git a/fs/fs_parser.c b/fs/fs_parser.c
index 0d388faa25d1..460ea4206fa2 100644
--- a/fs/fs_parser.c
+++ b/fs/fs_parser.c
@@ -264,6 +264,7 @@ int fs_lookup_param(struct fs_context *fc,
return invalf(fc, "%s: not usable as path", param->key);
}
+ f->refcnt++; /* filename_lookup() drops our ref. */
ret = filename_lookup(param->dirfd, f, flags, _path, NULL);
if (ret < 0) {
errorf(fc, "%s: Lookup failure for '%s'", param->key, f->name);