X-Git-Url: https://git.enpas.org/?a=blobdiff_plain;f=plugins%2Fmod_posix.lua;h=95b950347476292956d264e51bd2748f527e7a27;hb=04cac3474b5d2ef6b40863e683ddb78997d739ee;hp=697930cab39266e11bc9f0cb5ae07399ad09822a;hpb=39287712ba6a8414fd235807dd504fdbb75507b6;p=prosody.git diff --git a/plugins/mod_posix.lua b/plugins/mod_posix.lua index 697930ca..95b95034 100644 --- a/plugins/mod_posix.lua +++ b/plugins/mod_posix.lua @@ -136,6 +136,7 @@ module:add_event_hook("server-stopped", remove_pidfile); if signal.signal then signal.signal("SIGTERM", function () module:log("warn", "Received SIGTERM"); + signal.signal("SIGTERM", function () end); -- Fixes us getting into some kind of loop prosody.unlock_globals(); prosody.shutdown("Received SIGTERM"); prosody.lock_globals(); @@ -149,6 +150,7 @@ if signal.signal then signal.signal("SIGINT", function () module:log("info", "Received SIGINT"); + signal.signal("SIGINT", function () end); -- Fix to not loop prosody.unlock_globals(); prosody.shutdown("Received SIGINT"); prosody.lock_globals();