Qinghuang Feng
7e6628544a
Btrfs: open_ctree() error handling can oops on fs_info
...
a bug in open_ctree:
struct btrfs_root *open_ctree(..)
{
....
if (!extent_root || !tree_root || !fs_info ||
!chunk_root || !dev_root || !csum_root) {
err = -ENOMEM;
goto fail;
//When code flow goes to "fail", fs_info may be NULL or uninitialized.
}
....
fail:
btrfs_close_devices(fs_info->fs_devices);// !
btrfs_mapping_tree_free(&fs_info->mapping_tree);// !
kfree(extent_root);
kfree(tree_root);
bdi_destroy(&fs_info->bdi);// !
...
)
Signed-off-by: Qinghuang Feng <qhfeng.kernel@gmail.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>
2009-01-21 10:49:16 -05:00
..
2009-01-05 21:25:51 -05:00
2009-01-21 10:49:16 -05:00
2008-11-06 22:03:00 -05:00
2008-12-11 16:30:39 -05:00
2009-01-06 09:38:55 -05:00
2009-01-21 10:49:16 -05:00
2008-10-29 14:49:59 -04:00
2009-01-07 19:56:59 -05:00
2009-01-05 21:25:51 -05:00
2009-01-21 10:49:16 -05:00
2009-01-05 21:25:51 -05:00
2009-01-21 10:49:16 -05:00
2008-12-08 16:46:26 -05:00
2009-01-05 21:25:51 -05:00
2008-09-25 11:04:06 -04:00
2009-01-21 10:49:16 -05:00
2008-12-12 10:03:38 -05:00
2009-01-21 10:49:16 -05:00
2008-11-10 07:34:43 -05:00
2009-01-21 10:49:16 -05:00
2009-01-06 11:42:00 -05:00
2009-01-21 10:49:16 -05:00
2009-01-05 21:25:51 -05:00
2008-09-25 11:04:06 -04:00
2008-12-02 09:54:17 -05:00
2009-01-05 21:25:51 -05:00
2009-01-21 10:59:08 -05:00
2009-01-21 10:49:16 -05:00
2009-01-16 11:59:08 -05:00
2009-01-05 21:25:51 -05:00
2008-09-25 11:04:06 -04:00
2008-10-29 14:49:59 -04:00
2009-01-21 10:59:08 -05:00
2008-12-08 16:58:54 -05:00
2008-09-25 11:04:05 -04:00
2009-01-05 21:25:51 -05:00
2008-09-25 11:03:56 -04:00
2009-01-05 21:25:51 -05:00
2008-09-29 15:18:18 -04:00
2009-01-05 21:25:51 -05:00
2009-01-05 21:25:51 -05:00
2009-01-21 10:49:16 -05:00
2009-01-05 21:25:51 -05:00
2009-01-21 10:59:08 -05:00
2009-01-05 21:25:51 -05:00
2009-01-05 21:25:51 -05:00
2009-01-09 13:14:17 -05:00
2008-09-25 11:04:07 -04:00
2008-09-25 15:41:59 -04:00
2008-11-19 21:17:22 -05:00
2009-01-21 10:59:08 -05:00
2008-12-12 10:03:26 -05:00
2009-01-21 10:49:16 -05:00
2008-09-25 11:04:07 -04:00
2009-01-05 21:25:51 -05:00