diff options
author | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2009-01-30 11:47:58 -0800 |
---|---|---|
committer | Stephen Hemminger <stephen.hemminger@vyatta.com> | 2009-01-30 11:47:58 -0800 |
commit | aa8ecb694dc85cb67e2c9f7b5fe911888d0310e4 (patch) | |
tree | d43801afd8bfb22ac3d2eea7831fbac1d29ff5c3 /lib/Vyatta/Qos/TrafficLimiter.pm | |
parent | f5514e84e3585b6ed0c3d82453083a9ecd236c65 (diff) | |
download | vyatta-cfg-qos-aa8ecb694dc85cb67e2c9f7b5fe911888d0310e4.tar.gz vyatta-cfg-qos-aa8ecb694dc85cb67e2c9f7b5fe911888d0310e4.zip |
Fix error handling when no bandwidth specified
Bugfix 4075
Correctly report error message.
Diffstat (limited to 'lib/Vyatta/Qos/TrafficLimiter.pm')
-rw-r--r-- | lib/Vyatta/Qos/TrafficLimiter.pm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Vyatta/Qos/TrafficLimiter.pm b/lib/Vyatta/Qos/TrafficLimiter.pm index 5c6abba..9b47be8 100644 --- a/lib/Vyatta/Qos/TrafficLimiter.pm +++ b/lib/Vyatta/Qos/TrafficLimiter.pm @@ -51,8 +51,8 @@ my @matches = (); my $rate = $config->returnValue("bandwidth"); + die "bandwidth must be defined for $level\n" unless $rate; $self->{rate} = getRate($rate); - defined $rate or die "bandwidth must be defined for $level\n"; $self->{burst} = $config->returnValue("burst"); defined $self->{burst} or die "burst must be defined for $level\n"; |