summaryrefslogtreecommitdiffstats
path: root/etc/inc
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2014-04-17 12:56:45 +0000
committerErmal <eri@pfsense.org>2014-04-17 12:56:45 +0000
commitc93f46fea402a3d593e0418d8105948beabfca38 (patch)
treeb02e048f3ef3ca180d0e4b64d95564bd2d0d9d8c /etc/inc
parent7896c39c1a969a79c606b6d0b97581bfb4a12d49 (diff)
parent5e5c72be38dd37fabe4ab2eab87fa77fd26f2371 (diff)
downloadpfsense-c93f46fea402a3d593e0418d8105948beabfca38.zip
pfsense-c93f46fea402a3d593e0418d8105948beabfca38.tar.gz
Merge pull request #1096 from fraenki/fix_pbi_services
Diffstat (limited to 'etc/inc')
-rw-r--r--etc/inc/service-utils.inc6
1 files changed, 3 insertions, 3 deletions
diff --git a/etc/inc/service-utils.inc b/etc/inc/service-utils.inc
index 59bd7ec..f137160 100644
--- a/etc/inc/service-utils.inc
+++ b/etc/inc/service-utils.inc
@@ -50,7 +50,7 @@ function write_rcfile($params) {
global $g;
$rcfile_fullname = RCFILEPREFIX . $params['file'];
- if (!file_exists($rcfile_fullname) && !touch($rcfile_fullname))
+ if (!file_exists($rcfile_fullname) && !is_link($rcfile_fullname) && !touch($rcfile_fullname))
return false;
if (!is_writable($rcfile_fullname) || empty($params['start']))
@@ -100,7 +100,7 @@ function start_service($name) {
if (!empty($service['prefix'])) {
$prefix =& $service['prefix'];
}
- if(file_exists("{$prefix}{$service['rcfile']}")) {
+ if(file_exists("{$prefix}{$service['rcfile']}") || is_link("{$prefix}{$service['rcfile']}")) {
mwexec_bg("{$prefix}{$service['rcfile']} start");
}
}
@@ -126,7 +126,7 @@ function stop_service($name) {
if(!empty($service['prefix'])) {
$prefix =& $service['prefix'];
}
- if(file_exists("{$prefix}{$service['rcfile']}")) {
+ if(file_exists("{$prefix}{$service['rcfile']}") || is_link("{$prefix}{$service['rcfile']}")) {
mwexec("{$prefix}{$service['rcfile']} stop");
}
return;
OpenPOWER on IntegriCloud