1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-18 10:04:20 +03:00

Fix snapshot lvcreate activation check.

This commit is contained in:
Alasdair Kergon 2002-11-22 14:19:56 +00:00
parent 50d7e96c6d
commit 8c54f03db8

View File

@ -399,14 +399,12 @@ static int _lvcreate(struct cmd_context *cmd, struct lvcreate_params *lp)
lp->extents = lp->extents - size_rest + lp->stripes; lp->extents = lp->extents - size_rest + lp->stripes;
} }
if (lp->snapshot) {
if (!activation()) { if (!activation()) {
if (lp->snapshot)
log_error("Can't create snapshot without using " log_error("Can't create snapshot without using "
"device-mapper kernel driver"); "device-mapper kernel driver");
return 0; return 0;
} }
if (lp->snapshot) {
if (!(org = find_lv(vg, lp->origin))) { if (!(org = find_lv(vg, lp->origin))) {
log_err("Couldn't find origin volume '%s'.", log_err("Couldn't find origin volume '%s'.",
lp->origin); lp->origin);