Changeset

2073:72784ce0c0e0

mod_posix: Switch config option to 'daemonize', fall back to 'no_daemonize' if not set, default behaviour remains the same... daemonize if mod_posix is loaded
author Matthew Wild <mwild1@gmail.com>
date Sun, 08 Nov 2009 15:10:44 +0000
parents 2072:464a5392bc80
children 2074:c59c8f3ec645
files plugins/mod_posix.lua
diffstat 1 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_posix.lua	Sun Nov 08 15:09:11 2009 +0000
+++ b/plugins/mod_posix.lua	Sun Nov 08 15:10:44 2009 +0000
@@ -102,7 +102,12 @@
 end
 require "core.loggingmanager".register_sink_type("syslog", syslog_sink_maker);
 
-if not module:get_option("no_daemonize") then
+local daemonize = module:get_option("daemonize");
+if daemonize == nil then
+	daemonize = not module:get_option("no_daemonize"); --COMPAT w/ 0.5
+end
+
+if daemonize then
 	local function daemonize_server()
 		local ok, ret = pposix.daemonize();
 		if not ok then