فهرست منبع

init: change return value when starting corosync

When corosync is started by systemd, it would be considered
as failed because it returns a non-zero value, even though it
starts sucessfully.

Signed-off-by: Lidong Zhong <lzhong@suse.com>
Signed-off-by: Xia Li<xli@suse.com>
Reviewed-by: Jan Friesse <jfriesse@redhat.com>
Lidong Zhong 11 سال پیش
والد
کامیت
7a6cc6b5a2
1فایلهای تغییر یافته به همراه3 افزوده شده و 3 حذف شده
  1. 3 3
      init/corosync.in

+ 3 - 3
init/corosync.in

@@ -39,13 +39,13 @@ failure()
 status()
 {
 	pid=$(pidof $1 2>/dev/null)
-	rtrn=$?
-	if [ $rtrn -ne 0 ]; then
+	res=$?
+	if [ $res -ne 0 ]; then
 		echo "$1 is stopped"
 	else
 		echo "$1 (pid $pid) is running..."
 	fi
-	return $rtrn
+	return $res
 }
 
 # rpm based distros