dm thin metadata: Avoid returning cmd->bm wild pointer on error
authorYe Bin <yebin10@huawei.com>
Tue, 1 Sep 2020 06:25:43 +0000 (14:25 +0800)
committerMike Snitzer <snitzer@redhat.com>
Wed, 2 Sep 2020 17:38:31 +0000 (13:38 -0400)
commit219403d7e56f9b716ad80ab87db85d29547ee73e
tree8b894a3e1f48592327f89f7d31c9ef24f5c79bf8
parentd16ff19e69ab57e08bf908faaacbceaf660249de
dm thin metadata:  Avoid returning cmd->bm wild pointer on error

Maybe __create_persistent_data_objects() caller will use PTR_ERR as a
pointer, it will lead to some strange things.

Signed-off-by: Ye Bin <yebin10@huawei.com>
Cc: stable@vger.kernel.org
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
drivers/md/dm-thin-metadata.c