From 7cf3e98090a3e9f0a9cc960d07c5f259adab6a19 Mon Sep 17 00:00:00 2001
From: Marius Cramer <m.cramer@pixcept.de>
Date: Thu, 14 Nov 2013 08:39:08 -0500
Subject: [PATCH] Merge remote-tracking branch 'origin/stable-3.0.5'
---
server/mods-available/rescue_core_module.inc.php | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/server/mods-available/rescue_core_module.inc.php b/server/mods-available/rescue_core_module.inc.php
index 050d32f..f1b25bd 100644
--- a/server/mods-available/rescue_core_module.inc.php
+++ b/server/mods-available/rescue_core_module.inc.php
@@ -433,7 +433,8 @@
*/
private function _rescueDaemon($daemon){
global $conf;
-
+
+ $app->uses('system');
// if you need to find all restarts search for "['init_scripts']"
/*
* First we stop the running service "normally"
@@ -445,8 +446,8 @@
* So we have to try to stop but if this will not work, we have to kill the stopping
* of the service
*/
- exec($conf['init_scripts'] . '/' . $daemon . ' stop && (sleep 3; kill $!; sleep 2; kill -9 $!) &> /dev/null');
-
+ exec($app->system->getinitcommand($daemon, 'stop').' && (sleep 3; kill $!; sleep 2; kill -9 $!) &> /dev/null');
+
/*
* OK, we tryed to stop it normally, maybe this worked maybe not. So we have to look
* if the service is already running or not. If so, we have to kill them hard
@@ -456,7 +457,7 @@
/*
* There are no more zombies left. Lets start the service..
*/
- exec($conf['init_scripts'] . '/' . $daemon . ' start');
+ exec($app->system->getinitcommand($daemon, 'start'));
}
}
?>
--
Gitblit v1.9.1