From 8e5ab3bad6b6cfc7128e56d89d1633832f4187b6 Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Thu, 27 Oct 2011 14:25:34 +0200 Subject: Fix non-numeric comparison Regression from previous commit. Need to compare numeric not string value. --- lib/Vyatta/Qos/Util.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/Vyatta') diff --git a/lib/Vyatta/Qos/Util.pm b/lib/Vyatta/Qos/Util.pm index 3330c3e..5782fa9 100644 --- a/lib/Vyatta/Qos/Util.pm +++ b/lib/Vyatta/Qos/Util.pm @@ -98,7 +98,7 @@ sub getRate { if ($num == 0); die "$rate is not a valid bandwidth (negative value)\n" - if ($rate < 0); + if ($num < 0); if ( defined $suffix ) { my $scale = $rates{ lc $suffix }; -- cgit v1.2.3