summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wendler <polynomial-c@gentoo.org>2021-04-29 11:30:44 +0200
committerLars Wendler <polynomial-c@gentoo.org>2021-04-29 11:30:44 +0200
commit03882029a2dcbe2aa9df402b36788db33ac94b9d (patch)
treedc3ef18fdcd450320bcd83d5435fa366b0a9d3b4
parentrolltarball.sh: Use bash features as we already have bash in shebang (diff)
downloadapache-03882029a2dcbe2aa9df402b36788db33ac94b9d.tar.gz
apache-03882029a2dcbe2aa9df402b36788db33ac94b9d.tar.bz2
apache-03882029a2dcbe2aa9df402b36788db33ac94b9d.zip
Minor shell style fixesHEADmaster
Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
-rwxr-xr-x2.4/init/apache2.initd12
-rw-r--r--2.4/scripts/apache2ctl2
2 files changed, 7 insertions, 7 deletions
diff --git a/2.4/init/apache2.initd b/2.4/init/apache2.initd
index fc09ddd..0058e20 100755
--- a/2.4/init/apache2.initd
+++ b/2.4/init/apache2.initd
@@ -72,12 +72,12 @@ checkconfig() {
OUTPUT=$( ${APACHE2} ${APACHE2_OPTS} -t 2>&1 )
ret=$?
- if [ $ret -ne 0 ]; then
+ if [ ${ret} -ne 0 ]; then
eerror "${SVCNAME} has detected an error in your setup:"
printf "%s\n" "${OUTPUT}"
fi
- return $ret
+ return ${ret}
}
start() {
@@ -96,12 +96,12 @@ start() {
${APACHE2} ${APACHE2_OPTS} -k start
local i=0 retval=1
- while [ $i -lt ${TIMEOUT} ] ; do
+ while [ ${i} -lt ${TIMEOUT} ] ; do
if [ -e "${PIDFILE}" ] ; then
retval=0
break
fi
- sleep 1 && i=$(expr $i + 1)
+ sleep 1 && i=$(expr ${i} + 1)
done
eend ${retval}
@@ -123,8 +123,8 @@ stop() {
local i=0 retval=0
while ( test -f "${PIDFILE}" || pgrep -P ${PID} apache2 >/dev/null ) \
- && [ $i -lt ${TIMEOUT} ]; do
- sleep 1 && i=$(expr $i + 1)
+ && [ ${i} -lt ${TIMEOUT} ]; do
+ sleep 1 && i=$(expr ${i} + 1)
done
[ -e "${PIDFILE}" ] && retval=1
diff --git a/2.4/scripts/apache2ctl b/2.4/scripts/apache2ctl
index 872044b..890ded5 100644
--- a/2.4/scripts/apache2ctl
+++ b/2.4/scripts/apache2ctl
@@ -89,7 +89,7 @@ configdump() {
}
-if ! is_systemd; then
+if ! is_systemd ; then
# If systemd IS NOT detected, run the legacy apache2ctl code
# If first parameter is a verb defined in $RC_VERBS, pass the command to init script.