mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Unlink pid file before starting a new process
This commit is contained in:
parent
a11bc49704
commit
fe2eb9952f
@ -424,12 +424,15 @@ function captiveportal_init_webgui_zone($cpcfg) {
|
||||
"", "", "", "lighty-{$cpzone}-CaptivePortal.pid", $listenporthttp, "/usr/local/captiveportal",
|
||||
"", "", $cpzone);
|
||||
|
||||
@unlink("{$g['varrun']}/lighty-{$cpzone}-CaptivePortal.pid");
|
||||
/* attempt to start lighttpd */
|
||||
$res = mwexec("/usr/local/sbin/lighttpd -f {$g['varetc_path']}/lighty-{$cpzone}-CaptivePortal.conf");
|
||||
|
||||
/* fire up https instance */
|
||||
if (isset($cpcfg['httpslogin']))
|
||||
if (isset($cpcfg['httpslogin'])) {
|
||||
@unlink("{$g['varrun']}/lighty-{$cpzone}-CaptivePortal-SSL.pid");
|
||||
$res = mwexec("/usr/local/sbin/lighttpd -f {$g['varetc_path']}/lighty-{$cpzone}-CaptivePortal-SSL.conf");
|
||||
}
|
||||
}
|
||||
|
||||
/* reinit will disconnect all users, be careful! */
|
||||
|
||||
Loading…
Reference in New Issue
Block a user