rename_snapshot: fix parameter checks
both source and target snapshot need to be provided when renaming. Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com> Signed-off-by: Alexandre Derumier <alexandre.derumier@groupe-cyllene.com>
This commit is contained in:
committed by
Wolfgang Bumiller
parent
f32e25f920
commit
615da71f77
@ -2348,7 +2348,8 @@ sub rename_snapshot {
|
||||
my ($cfg, $volid, $source_snap, $target_snap) = @_;
|
||||
|
||||
die "no volid provided\n" if !$volid;
|
||||
die "no source or target snap provided\n" if !$source_snap && !$target_snap;
|
||||
die "no source snapshot provided\n" if !$source_snap;
|
||||
die "no target snapshot provided\n" if !$target_snap;
|
||||
|
||||
my ($storeid, $volname) = parse_volume_id($volid);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user