Commit 7bb5ba1f authored by Pavel Emelyanov's avatar Pavel Emelyanov

fsnotify: Don't crash on bad fsnotify mark type

This can be broken image, need to handle this error gracefully.
Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent ccdcb3d3
...@@ -295,8 +295,10 @@ static int restore_one_fanotify(int fd, struct fsnotify_mark_info *mark) ...@@ -295,8 +295,10 @@ static int restore_one_fanotify(int fd, struct fsnotify_mark_info *mark)
fme->s_dev, buf, sizeof(buf), &target); fme->s_dev, buf, sizeof(buf), &target);
if (!path) if (!path)
goto err; goto err;
} else } else {
BUG(); pr_err("Bad fsnotify mark type %d\n", fme->type);
goto err;
}
flags |= fme->mflags; flags |= fme->mflags;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment