25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-24 16:23:40 +01:00

Forget prepared SQL queries on database connect (#1325)

This commit is contained in:
Alexey Shchepin 2017-04-03 16:30:02 +03:00
parent b75780b9cd
commit f45dc46856

View File

@ -301,6 +301,12 @@ connecting(connect, #state{host = Host} = State) ->
case ConnectRes of
{ok, Ref} ->
erlang:monitor(process, Ref),
lists:foreach(
fun({{?PREPARE_KEY, _} = Key, _}) ->
erase(Key);
(_) ->
ok
end, get()),
PendingRequests =
p1_queue:dropwhile(
fun(Req) ->