From f951740b42b7112eff0cf677174638a34d7787d4 Mon Sep 17 00:00:00 2001 From: Than Ngo Date: Tue, 31 Oct 2000 17:35:17 +0000 Subject: fix the adding default route if GATEWAY" = "0.0.0.0 --- sysconfig/network-scripts/network-functions | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'sysconfig') diff --git a/sysconfig/network-scripts/network-functions b/sysconfig/network-scripts/network-functions index d4459a56..8b726a83 100644 --- a/sysconfig/network-scripts/network-functions +++ b/sysconfig/network-scripts/network-functions @@ -84,7 +84,11 @@ add_default_route () find_gateway_dev if [ "${GATEWAY}" != "" -a "${GATEWAY}" != "none" -a "${GATEWAYDEV}" != "" ] ; then if ! check_device_down ; then - /sbin/route add default gw ${GATEWAY} ${GATEWAYDEV} + if [ "$GATEWAY" = "0.0.0.0" ]; then + /sbin/route add default ${GATEWAYDEV} + else + /sbin/route add default gw ${GATEWAY} ${GATEWAYDEV} + fi fi fi } -- cgit v1.2.1