mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-01-26 21:35:16 +00:00
l2cap-ertm: fix l2cap data dispatch for ertm
This commit is contained in:
parent
550189ff21
commit
3c412221cc
@ -2925,7 +2925,7 @@ static void l2cap_acl_handler(uint8_t packet_type, uint16_t channel, uint8_t *pa
|
||||
l2cap_channel->req_seq = l2cap_channel->expected_tx_seq;
|
||||
|
||||
// process SDU
|
||||
l2cap_ertm_handle_in_sequence_sdu(l2cap_channel, sar, &packet[COMPLETE_L2CAP_HEADER+2], size-(COMPLETE_L2CAP_HEADER+2));
|
||||
l2cap_ertm_handle_in_sequence_sdu(l2cap_channel, sar, &packet[COMPLETE_L2CAP_HEADER+2], size-(COMPLETE_L2CAP_HEADER+2+2));
|
||||
|
||||
// process stored segments
|
||||
while (1){
|
||||
@ -2955,7 +2955,7 @@ static void l2cap_acl_handler(uint8_t packet_type, uint16_t channel, uint8_t *pa
|
||||
int delta = (tx_seq - l2cap_channel->expected_tx_seq) & 0x3f;
|
||||
if (delta < 2){
|
||||
// store segment
|
||||
l2cap_ertm_handle_out_of_sequence_sdu(l2cap_channel, sar, delta, &packet[COMPLETE_L2CAP_HEADER+2], size-(COMPLETE_L2CAP_HEADER+2));
|
||||
l2cap_ertm_handle_out_of_sequence_sdu(l2cap_channel, sar, delta, &packet[COMPLETE_L2CAP_HEADER+2], size-(COMPLETE_L2CAP_HEADER+2+2));
|
||||
|
||||
log_info("Received unexpected frame TxSeq %u but expected %u -> send S-SREJ", tx_seq, l2cap_channel->expected_tx_seq);
|
||||
l2cap_channel->send_supervisor_frame_selective_reject = 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user