Skip to content

Commit

Permalink
hypfs_kill_super(): deal with failed allocations
Browse files Browse the repository at this point in the history
hypfs_fill_super() might fail to allocate sbi; hypfs_kill_super()
should not oops on that.

Cc: stable@vger.kernel.org
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
  • Loading branch information
Al Viro committed Apr 16, 2018
1 parent 60cc43f commit a24cd49
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/s390/hypfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ static void hypfs_kill_super(struct super_block *sb)

if (sb->s_root)
hypfs_delete_tree(sb->s_root);
if (sb_info->update_file)
if (sb_info && sb_info->update_file)
hypfs_remove(sb_info->update_file);
kfree(sb->s_fs_info);
sb->s_fs_info = NULL;
Expand Down

0 comments on commit a24cd49

Please sign in to comment.