diff options
author | Matthew Wild <mwild1@gmail.com> | 2009-04-22 20:14:11 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2009-04-22 20:14:11 +0100 |
commit | 77195f9fb9f2092fc2ac3fc379185a9210de2a57 (patch) | |
tree | e57cf40c3f3d1cac021d60e36ddcf5d1a95f8133 /prosody | |
parent | 84bdf9494c891172c03f81186e0e8ff1a39364d7 (diff) | |
parent | fc2a4159849cf5fcb2c53d4fb0c0f1a7b101d69a (diff) | |
download | prosody-77195f9fb9f2092fc2ac3fc379185a9210de2a57.tar.gz prosody-77195f9fb9f2092fc2ac3fc379185a9210de2a57.zip |
Merge with 0.4.1
Diffstat (limited to 'prosody')
-rwxr-xr-x | prosody | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -160,6 +160,7 @@ end -- Global function to initiate prosody shutdown function prosody_shutdown(reason) log("info", "Shutting down: %s", reason or "unknown reason"); + eventmanager.fire_event("server-stopping", { reason = reason }); server.setquitting(true); end @@ -198,6 +199,8 @@ while select(2, xpcall(server.loop, catch_uncaught_error)) ~= "quitting" do socket.sleep(0.2); end +eventmanager.fire_event("server-cleanup"); + -- Ok, we're quitting I know, but we -- need to do some tidying before we go :) server.setquitting(false); @@ -224,3 +227,5 @@ for hostname, host in pairs(hosts) do end server.closeall(); + +eventmanager.fire_event("server-stopped"); |