summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorKarolin Seeger <kseeger@samba.org>2009-01-05 16:33:00 +0100
committerKarolin Seeger <kseeger@samba.org>2009-01-28 09:39:56 +0100
commit63bc7a8447eb7dfca228829dc428f791e4a01bae (patch)
tree491ce63d6f19dda38aeacf08477f84ed9456c6a8 /examples
parent627eb5683b7e2439d70f35c96f41f86ed5898383 (diff)
downloadsamba-63bc7a8447eb7dfca228829dc428f791e4a01bae.tar.gz
samba-63bc7a8447eb7dfca228829dc428f791e4a01bae.tar.xz
samba-63bc7a8447eb7dfca228829dc428f791e4a01bae.zip
examples: Avoid bashism in perfcount.init.
This fixes bug #6000. Thanks to the Debian Samba package maintainers for providing the patch! Remove trailing whitespaces. Karolin (cherry picked from commit 2e09746a4db4186c9d648370b9004971bc18e5c9) (cherry picked from commit 9b17f7907bca32282d6e56fa28ca62ef84bf7afc) (cherry picked from commit de41f0e9a08b796873bdd319fe784b6c90e28b23)
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/perfcounter/perfcountd.init6
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/perfcounter/perfcountd.init b/examples/perfcounter/perfcountd.init
index b82aea92309..0beff962276 100755
--- a/examples/perfcounter/perfcountd.init
+++ b/examples/perfcounter/perfcountd.init
@@ -24,14 +24,14 @@ PATH=/bin:/usr/bin:/sbin:/usr/sbin
killproc()
{
pid=`ps aux | grep $1 | egrep -v '(grep|perfcountd)' | awk '{print $2}'`
- if [ "$pid" != "" ]; then
+ if [ x"$pid" != "x" ]; then
kill $pid
fi
}
# Start/stop processes
-case "$1"
+case "$1"
in
start)
/opt/samba/bin/perfcount -d -f /var/lib/samba/perfmon 2> /dev/null
@@ -47,7 +47,7 @@ stop)
status)
pid=`ps aux | grep perfcount | egrep -v '(grep|perfcountd)' | awk '{print $2}'`
- if [ "$pid" == "" ]; then
+ if [ x"$pid" = "x" ]; then
echo "Dead!"
exit 2;
fi