Skip to content

Commit 1c79ce0

Browse files
sjancrlubos
authored andcommitted
[nrf fromlist] Bluetooth: Host: L2CAP: Fix seg_recv call on SDU overflow
This fix calling seg_recv() callback being called even though channel is being disconnected due to SDU overflow. Upstream PR #: 80911 Signed-off-by: Szymon Janc <[email protected]>
1 parent 3adbc32 commit 1c79ce0

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

subsys/bluetooth/host/l2cap.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2557,6 +2557,7 @@ static void l2cap_chan_le_recv_seg_direct(struct bt_l2cap_le_chan *chan, struct
25572557
if (seg->len > sdu_remaining) {
25582558
LOG_WRN("L2CAP RX PDU total exceeds SDU");
25592559
bt_l2cap_chan_disconnect(&chan->chan);
2560+
return;
25602561
}
25612562

25622563
/* Commit receive. */

0 commit comments

Comments
 (0)