diff options
author | Badlop <badlop@process-one.net> | 2008-02-28 00:30:23 +0000 |
---|---|---|
committer | Badlop <badlop@process-one.net> | 2008-02-28 00:30:23 +0000 |
commit | 22a5bce9de9623e4b189b34319e59ddf84f828ea (patch) | |
tree | 0e8f28af4715715759543b5bd7f85f0affec4775 /src/mod_muc/mod_muc.erl | |
parent | * src/ejabberd_check.erl: Separate config loading from configuration sanity c... (diff) |
* src/ejabberd_app.erl (prep_stop): Stop modules when stopping
ejabberd (EJAB-536)
* src/mod_caps.erl (stop): Probably not needed to stop supervisor
child (EJAB-536)
* src/mod_muc/mod_muc.erl (room_destroyed): Catch message
sending (EJAB-536)
* src/mod_muc/mod_muc_room.erl (init): Ensure rooms are called
when the process dies due to a linked die (EJAB-536)
SVN Revision: 1212
Diffstat (limited to 'src/mod_muc/mod_muc.erl')
-rw-r--r-- | src/mod_muc/mod_muc.erl | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mod_muc/mod_muc.erl b/src/mod_muc/mod_muc.erl index 58ce97bb4..90a74b70f 100644 --- a/src/mod_muc/mod_muc.erl +++ b/src/mod_muc/mod_muc.erl @@ -91,8 +91,14 @@ stop(Host) -> gen_server:call(Proc, stop), supervisor:delete_child(ejabberd_sup, Proc). +%% This function is called by a room in three situations: +%% A) The owner of the room destroyed it +%% B) The only participant of a temporary room leaves it +%% C) mod_muc:stop was called, and each room is being terminated +%% In this case, the mod_muc process died before the room processes +%% So the message sending must be catched room_destroyed(Host, Room, Pid, ServerHost) -> - gen_mod:get_module_proc(ServerHost, ?PROCNAME) ! + catch gen_mod:get_module_proc(ServerHost, ?PROCNAME) ! {room_destroyed, {Room, Host}, Pid}, ok. |