mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-22 16:20:52 +01:00
* src/ejabberd_logger_h.erl: Added support for log rotation
SVN Revision: 160
This commit is contained in:
parent
e595ab91a0
commit
f4d2844be6
@ -1,3 +1,7 @@
|
|||||||
|
2003-10-27 Alexey Shchepin <alexey@sevcom.net>
|
||||||
|
|
||||||
|
* src/ejabberd_logger_h.erl: Added support for log rotation
|
||||||
|
|
||||||
2003-10-24 Alexey Shchepin <alexey@sevcom.net>
|
2003-10-24 Alexey Shchepin <alexey@sevcom.net>
|
||||||
|
|
||||||
* src/mod_offline.erl: Added function remove_old_messages/1
|
* src/mod_offline.erl: Added function remove_old_messages/1
|
||||||
|
@ -64,6 +64,14 @@ handle_call(_Request, State) ->
|
|||||||
%%----------------------------------------------------------------------
|
%%----------------------------------------------------------------------
|
||||||
handle_info({'EXIT', _Fd, _Reason}, _State) ->
|
handle_info({'EXIT', _Fd, _Reason}, _State) ->
|
||||||
remove_handler;
|
remove_handler;
|
||||||
|
handle_info({emulator, GL, reopen}, State) ->
|
||||||
|
file:close(State#state.fd),
|
||||||
|
case file:open(State#state.file, [append]) of
|
||||||
|
{ok, Fd} ->
|
||||||
|
{ok, State#state{fd = Fd}};
|
||||||
|
Error ->
|
||||||
|
Error
|
||||||
|
end;
|
||||||
handle_info({emulator, GL, Chars}, State) ->
|
handle_info({emulator, GL, Chars}, State) ->
|
||||||
write_event(State#state.fd, {erlang:localtime(), {emulator, GL, Chars}}),
|
write_event(State#state.fd, {erlang:localtime(), {emulator, GL, Chars}}),
|
||||||
{ok, State};
|
{ok, State};
|
||||||
|
Loading…
Reference in New Issue
Block a user