# HG changeset patch # User kleing # Date 1258783443 -39600 # Node ID 7277fa74120a87e3566df2b6b872561fced34590 # Parent e7289ca31aa055c92fb3c2dc5d5dc2fa30c917af add explicit platform check to wwwfind tool explicit platform check to avoid calling external programs with strange parameters diff -r e7289ca31aa0 -r 7277fa74120a src/Tools/WWW_Find/lib/Tools/wwwfind --- a/src/Tools/WWW_Find/lib/Tools/wwwfind Sat Nov 21 16:56:53 2009 +1100 +++ b/src/Tools/WWW_Find/lib/Tools/wwwfind Sat Nov 21 17:04:03 2009 +1100 @@ -33,6 +33,18 @@ exit 2 } +function checkplatform() +{ + PLAT=$(uname -s) + case "$PLAT" in + Linux) + ;; + *) + fail "Platform $PLAT currently not supported by $PRG component." + ;; + esac +} + function kill_by_port () { IPADDR='[0-9]*\.[0-9]*\.[0-9]*\.[0-9]*' PID=$(netstat -nltp 2>/dev/null \ @@ -46,6 +58,10 @@ netstat -latp 2>/dev/null | grep ":$1 " } +## platform support check + +checkplatform + ## process command line case "$1" in