提交 0463bb4e 编写于 作者: J Jim Meyering 提交者: Chris Mason

Btrfs: disk-io.c (open_ctree): Don't deref. NULL upon failed kzalloc

Signed-off-by: NChris Mason <chris.mason@oracle.com>
上级 75ccf47d
......@@ -1371,7 +1371,8 @@ struct btrfs_root *open_ctree(struct super_block *sb,
struct btrfs_super_block *disk_super;
if (!extent_root || !tree_root || !fs_info) {
if (!extent_root || !tree_root || !fs_info ||
!chunk_root || !dev_root) {
err = -ENOMEM;
goto fail;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册