mirror of
https://gitlab.com/shorewall/code.git
synced 2024-12-18 20:30:43 +01:00
Handle ppp devices correctly in the 'enable' command.
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
b132176dae
commit
da4f7ee524
@ -916,7 +916,12 @@ add_gateway() # $1 = Delta $2 = Table Number
|
|||||||
delta=$1
|
delta=$1
|
||||||
|
|
||||||
if ! echo $route | fgrep -q ' nexthop '; then
|
if ! echo $route | fgrep -q ' nexthop '; then
|
||||||
route=`echo $route | sed 's/via/nexthop via/'`
|
if echo $route | fgrep -q via; then
|
||||||
|
route=`echo $route | sed 's/via/nexthop via/'`
|
||||||
|
else
|
||||||
|
route="nexthop $route"
|
||||||
|
fi
|
||||||
|
|
||||||
dev=$(find_device $route)
|
dev=$(find_device $route)
|
||||||
if [ -f ${VARDIR}/${dev}_weight ]; then
|
if [ -f ${VARDIR}/${dev}_weight ]; then
|
||||||
weight=`cat ${VARDIR}/${dev}_weight`
|
weight=`cat ${VARDIR}/${dev}_weight`
|
||||||
|
Loading…
Reference in New Issue
Block a user