Allow openrc to be loaded in zsh
This fix the test then detect OSX in GetOSVersion that break support of zsh.
Fixes bug #1233118
Change-Id: If243fbe59f8f08041327057425018d7ae0d13ab2
diff --git a/functions b/functions
index 83826f9..d9445fe 100644
--- a/functions
+++ b/functions
@@ -364,7 +364,7 @@
# GetOSVersion
GetOSVersion() {
# Figure out which vendor we are
- if [[ -n "`which sw_vers 2>/dev/null`" ]]; then
+ if [[ -x "`which sw_vers 2>/dev/null`" ]]; then
# OS/X
os_VENDOR=`sw_vers -productName`
os_RELEASE=`sw_vers -productVersion`