mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-26 16:26:24 +01:00
Use dirty_delete when removing the session.
There is no need for a transaction and has less overhead
This commit is contained in:
parent
674ee7f5f6
commit
a1205f347f
@ -521,10 +521,7 @@ handle_info(_, StateName, StateData) ->
|
|||||||
%%----------------------------------------------------------------------
|
%%----------------------------------------------------------------------
|
||||||
terminate(_Reason, _StateName, StateData) ->
|
terminate(_Reason, _StateName, StateData) ->
|
||||||
?DEBUG("terminate: Deleting session ~s", [StateData#state.id]),
|
?DEBUG("terminate: Deleting session ~s", [StateData#state.id]),
|
||||||
mnesia:transaction(
|
mnesia:dirty_delete({http_bind, StateData#state.id}),
|
||||||
fun() ->
|
|
||||||
mnesia:delete({http_bind, StateData#state.id})
|
|
||||||
end),
|
|
||||||
send_receiver_reply(StateData#state.http_receiver, {ok, terminate}),
|
send_receiver_reply(StateData#state.http_receiver, {ok, terminate}),
|
||||||
case StateData#state.waiting_input of
|
case StateData#state.waiting_input of
|
||||||
false ->
|
false ->
|
||||||
|
Loading…
Reference in New Issue
Block a user