Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 02717d98 authored by Joe Thornber's avatar Joe Thornber Committed by Mike Snitzer
Browse files

dm space map metadata: fix sm_bootstrap_get_count()



Must set 'result' accordingly rather than return it.

Signed-off-by: default avatarJoe Thornber <ejt@redhat.com>
Signed-off-by: default avatarMike Snitzer <snitzer@redhat.com>
parent c1c6156f
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -583,7 +583,9 @@ static int sm_bootstrap_get_count(struct dm_space_map *sm, dm_block_t b,
{
	struct sm_metadata *smm = container_of(sm, struct sm_metadata, sm);

	return b < smm->begin ? 1 : 0;
	*result = (b < smm->begin) ? 1 : 0;

	return 0;
}

static int sm_bootstrap_count_is_more_than_one(struct dm_space_map *sm,