1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-03-28 02:50:41 +03:00

Detect case of both merging_store and cow_store supplied in

_snap_text_import().
This commit is contained in:
Mike Snitzer 2010-01-15 17:46:08 +00:00
parent e47a591d76
commit eb9454ab68

View File

@ -46,9 +46,14 @@ static int _snap_text_import(struct lv_segment *seg, const struct config_node *s
old_suppress = log_suppress(1);
/* FIXME Detect case of both merging_store and cow_store supplied */
if ((cow_name = find_config_str(sn, "merging_store", NULL)))
if ((cow_name = find_config_str(sn, "merging_store", NULL))) {
if (find_config_str(sn, "cow_store", NULL)) {
log_suppress(old_suppress);
log_error("Both snapshot cow and merging storage were specified.");
return 0;
}
merge = 1;
}
else if (!(cow_name = find_config_str(sn, "cow_store", NULL))) {
log_suppress(old_suppress);
log_error("Snapshot cow storage not specified.");