Merge pull request #6841 from lafirest/fix/slow_subs_qos2

fix(emqx_slow_subs): fix qos2 pattern matching error
This commit is contained in:
lafirest 2022-01-24 17:35:25 +08:00 committed by GitHub
commit 0fadc85c15
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -392,7 +392,7 @@ pubrel(PacketId, Session = #session{awaiting_rel = AwaitingRel}) ->
| {error, emqx_types:reason_code()}). | {error, emqx_types:reason_code()}).
pubcomp(ClientInfo, PacketId, Session = #session{inflight = Inflight}) -> pubcomp(ClientInfo, PacketId, Session = #session{inflight = Inflight}) ->
case emqx_inflight:lookup(PacketId, Inflight) of case emqx_inflight:lookup(PacketId, Inflight) of
{value, {Pubrel, Msg}} when is_record(Pubrel, pubrel_await) -> {value, {#pubrel_await{message = Msg}, _Ts}} ->
on_delivery_completed(ClientInfo, Msg, Session), on_delivery_completed(ClientInfo, Msg, Session),
Inflight1 = emqx_inflight:delete(PacketId, Inflight), Inflight1 = emqx_inflight:delete(PacketId, Inflight),
dequeue(ClientInfo, Session#session{inflight = Inflight1}); dequeue(ClientInfo, Session#session{inflight = Inflight1});