When both sides detect a sequence number gap at the same time, they each send a ResendRequest. However, in AwaitingResend state, all messages with a sequence number above end_seq_number are unconditionally queued (session.rs, process_message). This means each side queues the other's ResendRequest instead of processing it, and neither side ever starts resending — creating a deadlock.
The fix is to exempt ResendRequest (type "2") and SequenceReset (type "4") from being queued, since they are part of the gap recovery mechanism itself and must always be processed immediately.