From: Hugo Villeneuve Date: Wed, 28 Aug 2013 00:38:39 +0000 (-0400) Subject: Replace = with == in bash string tests X-Git-Url: http://gitweb.hugovil.com/?a=commitdiff_plain;h=175a1744f1817f2dc147c5d28abbb3314f015be4;p=hvlinux.git Replace = with == in bash string tests --- diff --git a/stage1/bootscripts/rc b/stage1/bootscripts/rc index a85b893..f747bc8 100755 --- a/stage1/bootscripts/rc +++ b/stage1/bootscripts/rc @@ -61,7 +61,7 @@ trap ":" INT QUIT TSTP runlevel=${1} # If no runlevel was passed as an argument, we won't change runlevels. -if [ "${runlevel}" = "" ]; then +if [ "${runlevel}" == "" ]; then echo "Usage: ${0} " >&2 exit ${EXIT_CODE_FAILURE} fi @@ -137,7 +137,7 @@ for start_script in $(ls /etc/rc.d/rc${runlevel}.d/S* 2> /dev/null); do # If the service was not started in the previous level, or if we just # stopped it in this runlevel, then we need to start or restart it. check_script_status ${start_script} - if [ ${?} = ${EXIT_CODE_SUCCESS} ]; then + if [ ${?} == ${EXIT_CODE_SUCCESS} ]; then startup ${start_script} start retval=${?} if [ ${retval} -ne ${EXIT_CODE_SUCCESS} -a ${retval} -ne ${EXIT_CODE_WARNING} ]; then