[pve-devel] [PATCH qemu-server] Remove guest states to ensure no old states are exists

Dietmar Maurer dietmar at proxmox.com
Tue Jun 27 12:57:39 CEST 2017


>  PVE/API2/Qemu.pm | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm
> index da5f5b1..cf21afb 100644
> --- a/PVE/API2/Qemu.pm
> +++ b/PVE/API2/Qemu.pm
> @@ -449,6 +449,9 @@ __PACKAGE__->register_method({
>  	    $rpcenv->check_pool_exist($pool);
>  	}
>  
> +	# ensure no old replication state are exists
> +	PVE::ReplicationState::delete_guest_states($vmid);

Can we move this below the permission checks?

> +
>  	$rpcenv->check($authuser, "/storage/$storage", ['Datastore.AllocateSpace'])
>  	    if defined($storage);
>  
> -- 
> 2.11.0
> 
> 
> _______________________________________________
> pve-devel mailing list
> pve-devel at pve.proxmox.com
> https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel




More information about the pve-devel mailing list