25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-12-26 17:38:45 +01:00

Get rid of useless mnesia transaction (EJAB-1502)

This commit is contained in:
Evgeniy Khramtsov 2011-10-14 16:57:51 +10:00
parent c1d479f863
commit 96800e9b75

View File

@ -283,19 +283,16 @@ handle_session_start(Pid, XmppDomain, Sid, Rid, Attrs,
end,
XmppVersion = xml:get_attr_s("xmpp:version", Attrs),
?DEBUG("Create session: ~p", [Sid]),
mnesia:transaction(
fun() ->
mnesia:write(
#http_bind{id = Sid,
pid = Pid,
to = {XmppDomain,
XmppVersion},
hold = Hold,
wait = Wait,
process_delay = Pdelay,
version = Version
})
end),
mnesia:dirty_write(
#http_bind{id = Sid,
pid = Pid,
to = {XmppDomain,
XmppVersion},
hold = Hold,
wait = Wait,
process_delay = Pdelay,
version = Version
}),
handle_http_put(Sid, Rid, Attrs, Payload, PayloadSize, true, IP).
%%%----------------------------------------------------------------------