* [PATCH] dm space map metadata: Fix lost checking the return value of the 'apply_bops'.
@ 2019-08-19 3:31 ZhangXiaoxu
0 siblings, 0 replies; only message in thread
From: ZhangXiaoxu @ 2019-08-19 3:31 UTC (permalink / raw)
To: agk, snitzer, dm-devel, zhangxiaoxu5
In commit 6096d91af0b6 ("dm space map metadata: fix occasional leak
of a metadata block on resize"), we refactor the commit logical to
a new function 'apply_bops'.
But when replace it in 'out' function, the return value was not checked.
This may lead 'out' function return a wrong value to the caller.
Fixes: 6096d91af0b6 ("dm space map metadata: fix occasional leak of a
metadata block on resize")
Signed-off-by: ZhangXiaoxu <zhangxiaoxu5@huawei.com>
---
drivers/md/persistent-data/dm-space-map-metadata.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/md/persistent-data/dm-space-map-metadata.c b/drivers/md/persistent-data/dm-space-map-metadata.c
index aec4492..2532858 100644
--- a/drivers/md/persistent-data/dm-space-map-metadata.c
+++ b/drivers/md/persistent-data/dm-space-map-metadata.c
@@ -249,7 +249,7 @@ static int out(struct sm_metadata *smm)
}
if (smm->recursion_count == 1)
- apply_bops(smm);
+ r = apply_bops(smm);
smm->recursion_count--;
--
2.7.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2019-08-19 3:31 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-19 3:31 [PATCH] dm space map metadata: Fix lost checking the return value of the 'apply_bops' ZhangXiaoxu
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.