[pve-devel] [PATCH 3/6] setup_tc_rate_limit : delete class and filter before update

Alexandre DERUMIER aderumier at odiso.com
Tue Mar 5 13:13:44 CET 2013


>>this is the same: 
>>return if !$rate; 
>>
>>$rate can be 0 or undef 

Ok, got it.

is it ok like this for you dietmar ? (return if !$rate)

----- Mail original ----- 

De: "Stefan Priebe - Profihost AG" <s.priebe at profihost.ag> 
À: pve-devel at pve.proxmox.com 
Envoyé: Mardi 5 Mars 2013 12:39:04 
Objet: Re: [pve-devel] [PATCH 3/6] setup_tc_rate_limit : delete class and filter before update 

this is too complex 

+ return if (!$rate || ($rate && $rate == 0)); 

this is the same: 
return if !$rate; 

$rate can be 0 or undef 

Stefan 

Am 05.03.2013 12:20, schrieb Alexandre DERUMIER: 
>>> This expression makes no sense to me? Maybe we just need 
>>> 
>>> return if !$rate; 
> 
> pve-manager can send rate=0 to api2, is it filtered somewhere ? 
> (just to be sure, in perl, is 0 != undef ? ) 
> ----- Mail original ----- 
> 
> De: "Dietmar Maurer" <dietmar at proxmox.com> 
> À: "Alexandre Derumier" <aderumier at odiso.com>, pve-devel at pve.proxmox.com 
> Envoyé: Mardi 5 Mars 2013 11:52:23 
> Objet: RE: [pve-devel] [PATCH 3/6] setup_tc_rate_limit : delete class and filter before update 
> 
>> system("/sbin/tc qdisc del dev $iface root >/dev/null 2>&1"); 
>> 
>> + return if (!$rate || ($rate && $rate == 0)); 
> 
> This expression makes no sense to me? Maybe we just need 
> 
> return if !$rate; 
> _______________________________________________ 
> pve-devel mailing list 
> pve-devel at pve.proxmox.com 
> http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel 
> 
_______________________________________________ 
pve-devel mailing list 
pve-devel at pve.proxmox.com 
http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel 



More information about the pve-devel mailing list