mirror of
https://git.proxmox.com/git/qemu-server
synced 2025-07-04 03:58:37 +00:00
fix #5980: importdisk: fix spurious warning
if not target disk is given, it makes no sense to check that it is valid. Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
This commit is contained in:
parent
4b6051485e
commit
45fedd4729
@ -599,7 +599,7 @@ __PACKAGE__->register_method ({
|
||||
my $target_disk = extract_param($param, 'target-disk');
|
||||
|
||||
# do_import does not allow invalid drive names (e.g. unused0)
|
||||
$target_disk = undef if !is_valid_drivename($target_disk);
|
||||
$target_disk = undef if $target_disk && !is_valid_drivename($target_disk);
|
||||
|
||||
my $vm_conf = PVE::QemuConfig->load_config($vmid);
|
||||
PVE::QemuConfig->check_lock($vm_conf);
|
||||
|
Loading…
Reference in New Issue
Block a user