Bluetooth: RFCOMM: Fix MTU calculation in rfcomm_connected
The MTU calculation in rfcomm_connected() was incorrectly adding the FCS
size instead of subtracting it.
This could lead to buffer overflows when sending data that exceeds
the actual available space.
Fix the calculation by properly subtracting both the RFCOMM header size and
the FCS size from the L2CAP MTU to get the correct RFCOMM session MTU.
Signed-off-by:
Jiawei Yang <jiawei.yang_1@nxp.com>
Loading
Please sign in to comment