diff --git a/kernel/core_hook.c b/kernel/core_hook.c index fdf5a4f3..cf44fa3f 100644 --- a/kernel/core_hook.c +++ b/kernel/core_hook.c @@ -541,11 +541,13 @@ static void try_umount(const char *mnt, bool check_mnt, int flags) if (path.dentry != path.mnt->mnt_root) { // it is not root mountpoint, maybe umounted by others already. + path_put(&path); return; } // we are only interest in some specific mounts if (check_mnt && !should_umount(&path)) { + path_put(&path); return; }