From 96fa1f3494c9e45980108d51e2952a1516a86cb3 Mon Sep 17 00:00:00 2001 From: Tom Eastep Date: Wed, 7 Apr 2010 12:46:51 -0700 Subject: [PATCH] Fix find_first_interface_address() Signed-off-by: Tom Eastep --- Shorewall/lib.common | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Shorewall/lib.common b/Shorewall/lib.common index 1c3d304c4..2c58d0102 100644 --- a/Shorewall/lib.common +++ b/Shorewall/lib.common @@ -435,7 +435,11 @@ find_first_interface_address() # $1 = interface # # If there wasn't one, bail out now # - [ -n "$addr" ] || startup_error "Can't determine the IP address of $1" + if [ -z "$addr" ]; then + echo " ERROR: Can't determine the IP address of $1" >&2 + kill $$ + exit 1 + fi # # Strip off the trailing VLSM mask (or the peer IP in case of a P-t-P link) # along with everything else on the line