tunneldigger: build cmdline using function "append"

This commit is contained in:
Alexander Couzens 2014-01-27 05:32:29 +01:00
parent fd23c8cd31
commit 215df2b536
1 changed files with 3 additions and 6 deletions

View File

@ -21,15 +21,12 @@ config_cb() {
local broker_opts=""
for address in $addresses; do
broker_opts="${broker_opts} -b ${address}"
append broker_opts "-b ${address}"
done
if [ ! -z "${limit_bw_down}" ]; then
broker_opts="${broker_opts} -L ${limit_bw_down}"
fi
[ ! -z "${limit_bw_down}" ] && append broker_opts "-L ${limit_bw_down}"
[ ! -z "${hook_script}" ] && append broker_opts "-s ${hook_script}"
if [ ! -z "${hook_script}" ] ; then
broker_opts="${broker_opts} -s ${hook_script}"
fi
echo "Starting tunneldigger on ${interface}"