ia64/xen-unstable
changeset 7808:6d981d34cf52
Fix check for a working iptables installation. Checking for the iptables
binary is not sufficient, because the user may not have the appropriate
modules installed.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
binary is not sufficient, because the user may not have the appropriate
modules installed.
Signed-off-by: Ewan Mellor <ewan@xensource.com>
author | emellor@leeni.uk.xensource.com |
---|---|
date | Mon Nov 14 12:28:47 2005 +0100 (2005-11-14) |
parents | 2de6e301a640 |
children | bdf1a8039d13 bb270cb5d2e8 |
files | tools/examples/vif-common.sh |
line diff
1.1 --- a/tools/examples/vif-common.sh Mon Nov 14 12:12:29 2005 +0100 1.2 +++ b/tools/examples/vif-common.sh Mon Nov 14 12:28:47 2005 +0100 1.3 @@ -76,7 +76,11 @@ function frob_iptable() 1.4 # 1.5 function handle_iptable() 1.6 { 1.7 - if ! which iptables >&/dev/null 1.8 + # Check for a working iptables installation. Checking for the iptables 1.9 + # binary is not sufficient, because the user may not have the appropriate 1.10 + # modules installed. If iptables is not working, then there's no need to do 1.11 + # anything with it, so we can just return. 1.12 + if ! iptables -L >&/dev/null 1.13 then 1.14 return 1.15 fi