[pve-devel] [PATCH common] fix missing efidisk0 in api-dump

Thomas Lamprecht t.lamprecht at proxmox.com
Mon Jul 23 16:15:53 CEST 2018


Am 07/23/2018 um 12:11 PM schrieb Dominik Csapak:
> we now only skip properties when there is a -xx0 and we have -xx1, -xx2, etc.
> 
> previously we skipped all -xx0 entries if no -xx1 entry existed
> (which is the case for efidisk0)
> 
> Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
> ---
>   src/PVE/RESTHandler.pm | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/PVE/RESTHandler.pm b/src/PVE/RESTHandler.pm
> index 5d0c03d..205e6ef 100644
> --- a/src/PVE/RESTHandler.pm
> +++ b/src/PVE/RESTHandler.pm
> @@ -37,7 +37,7 @@ sub api_clone_schema {
>   		my ($name, $idx) = ($1, $2);
>   		if ($idx == 0 && defined($d->{"${name}1"})) {
>   		    $p = "${name}[n]";
> -		} elsif (defined($d->{"${name}0"})) {
> +		} elsif ($idx > 0 && defined($d->{"${name}0"})) {
>   		    next; # only handle once for -xx0, but only if -xx0 exists
>   		}
>   	    }
> 

applied, but re-wrote commit message as this addresses all possible
indexed paramteres with only one index

thanks




More information about the pve-devel mailing list