aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plugins/mod_posix.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/plugins/mod_posix.lua b/plugins/mod_posix.lua
index a5fd51ef..9155289d 100644
--- a/plugins/mod_posix.lua
+++ b/plugins/mod_posix.lua
@@ -79,6 +79,7 @@ local function write_pidfile()
end
pidfile = module:get_option("pidfile");
if pidfile then
+ local err;
local mode = stat(pidfile) and "r+" or "w+";
pidfile_handle, err = io.open(pidfile, mode);
if not pidfile_handle then