summaryrefslogtreecommitdiff
path: root/support-files/mysql.server.sh
diff options
context:
space:
mode:
Diffstat (limited to 'support-files/mysql.server.sh')
-rw-r--r--support-files/mysql.server.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/support-files/mysql.server.sh b/support-files/mysql.server.sh
index 8536ded7150..ed3240f124c 100644
--- a/support-files/mysql.server.sh
+++ b/support-files/mysql.server.sh
@@ -185,7 +185,11 @@ fi
user='@MYSQLD_USER@'
su_kill() {
- su - $user -s /bin/sh -c "kill $*" >/dev/null 2>&1
+ if test "$USER" = "$user"; then
+ kill $* >/dev/null 2>&1
+ else
+ su - $user -s /bin/sh -c "kill $*" >/dev/null 2>&1
+ fi
}
#