Unverified Commit 74d13ba5 authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!12426 btrfs: fix a NULL pointer dereference when failed to start a new trasacntion

parents 22311063 ddb15fcd
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -931,7 +931,7 @@ int btrfs_update_reloc_root(struct btrfs_trans_handle *trans,
	btrfs_grab_root(reloc_root);

	/* root->reloc_root will stay until current relocation finished */
	if (fs_info->reloc_ctl->merge_reloc_tree &&
	if (fs_info->reloc_ctl && fs_info->reloc_ctl->merge_reloc_tree &&
	    btrfs_root_refs(root_item) == 0) {
		set_bit(BTRFS_ROOT_DEAD_RELOC_TREE, &root->state);
		/*