Only add metric to dhcpcd if not given.

Fixes Gentoo #294312
This commit is contained in:
Roy Marples 2009-11-25 02:07:22 +00:00
parent ec38bbbdda
commit 4df8770a90

View File

@ -56,8 +56,11 @@ dhcpcd_start()
esac
done
# Add our route metric
[ "${metric:-0}" != "0" ] && args="${args} -m ${metric}"
# Add our route metric if not given
case " $args " in
*" -m "*) ;;
*) [ "${metric:-0}" != 0 ] && args="$args -m $metric";;
esac
# Bring up DHCP for this interface
ebegin "Running dhcpcd"