[pve-devel] [PATCH common 3/3] upid: fix calls to decode function

Fiona Ebner f.ebner at proxmox.com
Wed Oct 1 13:17:42 CEST 2025


Am 01.10.25 um 12:34 PM schrieb Thomas Lamprecht:
> Am 01.10.25 um 11:38 schrieb Fiona Ebner:
>> The decode function has a signature and always requires two arguments.
>> Otherwise, there will be errors like:
>>> Too few arguments for subroutine 'PVE::UPID::decode'
>>> (got 1; expected 2) at /usr/share/perl5/PVE/UPID.pm line 60.
> 
> I replaced this with just adapting the signature to have a default
> value for $noerr defined there, which avoids having to update
> call sides; as thanks to use v5.36 we can do
> 
> sub decode($upid, $noerr = 0) {
>     ...
> 
> 
> I also added a basic test harness to finally have some coverage
> here.

Oh, good to know that that's possible too :)




More information about the pve-devel mailing list