[23/99] dm exception store: fix failed set_chunk_size error path
From: Greg KH
Date: Fri Nov 06 2009 - 17:41:14 EST
2.6.31-stable review patch. If anyone has any objections, please let us know.
------------------
From: Mikulas Patocka <mpatocka@xxxxxxxxxx>
commit 0e8c4e4e3ebb15756ddc4170a88149a2cd323cfe upstream.
Properly close the device if failing because of an invalid chunk size.
Signed-off-by: Mikulas Patocka <mpatocka@xxxxxxxxxx>
Signed-off-by: Alasdair G Kergon <agk@xxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxx>
---
drivers/md/dm-exception-store.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/md/dm-exception-store.c
+++ b/drivers/md/dm-exception-store.c
@@ -251,7 +251,7 @@ int dm_exception_store_create(struct dm_
r = set_chunk_size(tmp_store, argv[2], &ti->error);
if (r)
- goto bad_cow;
+ goto bad_ctr;
r = type->ctr(tmp_store, 0, NULL);
if (r) {
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/