[pve-devel] [PATCH common 1/1] tools: add extract_sensitive_params

Thomas Lamprecht t.lamprecht at proxmox.com
Thu Dec 3 10:35:29 CET 2020


On 03.12.20 10:16, Wolfgang Bumiller wrote:
>> On 12/03/2020 9:47 AM Thomas Lamprecht <t.lamprecht at proxmox.com> wrote:
>> On 02.12.20 10:21, Dominik Csapak wrote:
>>> +    for my $opt (@$sensitive_list) {
>>> +	# First handle deletions as explicitly setting `undef`, afterwards new values may override
>>> +	# it.
>>
>> I know this is just copied, but there's no actual reason for setting to undef vs.
>> using delete encoded in that comment, it's just merely describing what one sees
>> when reading the code anyhow..
>>
>> @Wolfgang, you as original author (pve-storage commit 72385de9e23df) why did you
>> used undef vs. delete?
> 
> The update hooks in pve-storage don't get the deletion-list passed on as parameter,
> so I translated into putting `undef` into the parameter list.
> 

OK, then  that would be a much better comment here as it gives an
actual reason, something like

# delete by setting to undef so that add/update hooks can know about it






More information about the pve-devel mailing list