use new PVE::Storage::abs_filesystem_path()

The check_volume_access() method does no longer return a path.
This commit is contained in:
Dietmar Maurer 2013-10-01 12:41:06 +02:00
parent 92e3e2dab3
commit c9928b3d53

View File

@ -127,7 +127,7 @@ my $create_disks = sub {
$res->{$ds} = PVE::QemuServer::print_drive($vmid, $disk);
} else {
my $path = $rpcenv->check_volume_access($authuser, $storecfg, $vmid, $volid);
$rpcenv->check_volume_access($authuser, $storecfg, $vmid, $volid);
my $volid_is_new = 1;
@ -372,13 +372,8 @@ __PACKAGE__->register_method({
die "pipe requires cli environment\n"
if $rpcenv->{type} ne 'cli';
} else {
my $path = $rpcenv->check_volume_access($authuser, $storecfg, $vmid, $archive);
PVE::Storage::activate_volumes($storecfg, [ $archive ])
if PVE::Storage::parse_volume_id ($archive, 1);
die "can't find archive file '$archive'\n" if !($path && -f $path);
$archive = $path;
$rpcenv->check_volume_access($authuser, $storecfg, $vmid, $archive);
$archive = PVE::Storage::abs_filesystem_path($storecfg, $archive);
}
}