Avoid errors from 'status -i' when there are no optional interfaces

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2016-01-15 16:39:47 -08:00
parent f95c67ec6b
commit 9aa915a5e0

View File

@ -3272,9 +3272,11 @@ show_interfaces() {
local printed
for f in ${VARDIR}/*.status; do
if [ -f $f ]; then
interface=$(basename $f)
echo " Interface ${interface%.status} is $(interface_status $f)"
printed=Yes
fi
done
[ -n "$printed" ] && echo