From 86fae95d4e62c509cd627e82c60c024c0030460b Mon Sep 17 00:00:00 2001 From: Michael Tremer Date: Mon, 31 Oct 2011 19:39:30 +0000 Subject: [PATCH] Fix setting the default route when there are zones without a gateway setting. --- functions.routing | 3 +++ 1 file changed, 3 insertions(+) diff --git a/functions.routing b/functions.routing index 3a52ce4a..05cd1b29 100644 --- a/functions.routing +++ b/functions.routing @@ -49,8 +49,11 @@ function routing_default_update() { if [ "$(routing_db_get ${zone} ${proto} active)" = "1" ]; then gateway=$(routing_db_get ${zone} ${proto} remote-ip-address) + [ -z "${gateway}" ] && continue + weight=$(routing_db_get ${zone} ${proto} weight) + assert device_exists ${zone} if device_is_ppp ${zone}; then routes="${routes} dev ${zone}" else -- 2.47.2