Fixed the erasing of packets after retransmissions