1
0
mirror of https://gitlab.com/libvirt/libvirt.git synced 2024-12-23 21:34:54 +03:00

virsh-snapshot: Use the mutually exclusive params macro in cmdSnapshotEdit

This commit is contained in:
Peter Krempa 2013-03-07 11:17:48 +01:00
parent 4baf00fc30
commit 29882a054e

View File

@ -561,11 +561,7 @@ cmdSnapshotEdit(vshControl *ctl, const vshCmd *cmd)
bool rename_okay = vshCommandOptBool(cmd, "rename");
bool clone_okay = vshCommandOptBool(cmd, "clone");
if (rename_okay && clone_okay) {
vshError(ctl, "%s",
_("--rename and --clone are mutually exclusive"));
return false;
}
VSH_EXCLUSIVE_OPTIONS_EXPR("rename", rename_okay, "clone", clone_okay)
if (vshCommandOptBool(cmd, "current") &&
vshCommandOptBool(cmd, "snapshotname"))