aboutsummaryrefslogtreecommitdiffstats
path: root/packages/bandwidthd
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2007-02-20 04:04:17 +0000
committerScott Ullrich <sullrich@pfsense.org>2007-02-20 04:04:17 +0000
commit959dbc00362ba9a4e35843a8563c52005e4ed151 (patch)
tree62b7fcc9af85907ecfe034b838fce2ed80e9c358 /packages/bandwidthd
parent77e3a1a8b024bcec7a40f1c17e44a32a573a2600 (diff)
downloadpfsense-packages-959dbc00362ba9a4e35843a8563c52005e4ed151.tar.gz
pfsense-packages-959dbc00362ba9a4e35843a8563c52005e4ed151.tar.bz2
pfsense-packages-959dbc00362ba9a4e35843a8563c52005e4ed151.zip
Do not enumerate variable unless it is a variable.
Diffstat (limited to 'packages/bandwidthd')
-rw-r--r--packages/bandwidthd/bandwidthd.inc8
1 files changed, 5 insertions, 3 deletions
diff --git a/packages/bandwidthd/bandwidthd.inc b/packages/bandwidthd/bandwidthd.inc
index 6ac5fc52..67a251e7 100644
--- a/packages/bandwidthd/bandwidthd.inc
+++ b/packages/bandwidthd/bandwidthd.inc
@@ -100,9 +100,11 @@ function bandwidthd_install_config() {
/* initialize to "" */
$dev = "";
- foreach($ifdescrs as $ifdescr) {
- $descr = convert_friendly_interface_to_real_interface_name($ifdescr);
- $dev .= "dev \"$descr\"\n";
+ if(is_array($ifdescrs)) {
+ foreach($ifdescrs as $ifdescr) {
+ $descr = convert_friendly_interface_to_real_interface_name($ifdescr);
+ $dev .= "dev \"$descr\"\n";
+ }
}
$config_file = <<<EOF