From 2e5ff5d11c362468060df519598f6790f0491ffd Mon Sep 17 00:00:00 2001 From: Alasdair Kergon Date: Tue, 10 Jan 2012 02:03:31 +0000 Subject: Add dm_uuid_prefix/dm_set_uuid_prefix for non-lvm users to override hard-coded LVM- prefix. Try harder not to leave stray empty devices around (locally or remotely) when reverting changes after failures while there are inactive tables. --- lib/locking/locking.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'lib/locking') diff --git a/lib/locking/locking.c b/lib/locking/locking.c index 7dfd5fca..4b8a957b 100644 --- a/lib/locking/locking.c +++ b/lib/locking/locking.c @@ -515,7 +515,6 @@ int revert_lvs(struct cmd_context *cmd, struct dm_list *lvs) int suspend_lvs(struct cmd_context *cmd, struct dm_list *lvs, struct volume_group *vg_to_revert) { - struct dm_list *lvh; struct lv_list *lvl; dm_list_iterate_items(lvl, lvs) { @@ -523,11 +522,15 @@ int suspend_lvs(struct cmd_context *cmd, struct dm_list *lvs, log_error("Failed to suspend %s", lvl->lv->name); if (vg_to_revert) vg_revert(vg_to_revert); - dm_list_uniterate(lvh, lvs, &lvl->list) { - lvl = dm_list_item(lvh, struct lv_list); + /* + * FIXME Should be + * dm_list_uniterate(lvh, lvs, &lvl->list) { + * lvl = dm_list_item(lvh, struct lv_list); + * but revert would need fixing to use identical tree deps first. + */ + dm_list_iterate_items(lvl, lvs) if (!revert_lv(cmd, lvl->lv)) stack; - } return 0; } -- cgit