From d21177e5c786b5684365c4a323c1ec904c2e0a6e Mon Sep 17 00:00:00 2001 From: Roy Marples Date: Wed, 11 Nov 2009 00:31:32 +0000 Subject: Ensure we have a valid broadcast address. --- init.d/network.in | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'init.d/network.in') diff --git a/init.d/network.in b/init.d/network.in index 0d45cb9b..7bbe2535 100644 --- a/init.d/network.in +++ b/init.d/network.in @@ -107,8 +107,14 @@ intup=false runip() { local int="$1" err= - shift + + # Ensure we have a valid broadcast address + case "$@" in + *" broadcast "*|*" brd "*) ;; + *) set -- "$@" brd +;; + esac + err=$(LC_ALL=C ip address add "$@" dev "$int" 2>&1) if [ -z "$err" ]; then # ip does not bring up the interface when adding addresses -- cgit v1.2.3