Commit 5a430ee
Bluetooth: host: Fix L2CAP sent callback on disconnected channel
When receiving the L2CAP sent callbacks the dynamic L2CAP channel may
have been disconnected already. The user of the dynamic channel should
have received the disconnected and released callbacks for this channel
to release any resources for the data being sent, so simply ignoring
this sent callback is enough.
Fix sent callbacks by providing the CID to the callback instead of a
pointer to potentially released memory, and lookup the CID to check that
it is still valid.
Signed-off-by: Joakim Andersson <[email protected]>1 parent 79d575b commit 5a430ee
1 file changed
+22
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1661 | 1661 | | |
1662 | 1662 | | |
1663 | 1663 | | |
1664 | | - | |
| 1664 | + | |
| 1665 | + | |
1665 | 1666 | | |
1666 | | - | |
| 1667 | + | |
| 1668 | + | |
| 1669 | + | |
| 1670 | + | |
| 1671 | + | |
| 1672 | + | |
| 1673 | + | |
1667 | 1674 | | |
1668 | 1675 | | |
1669 | 1676 | | |
| |||
1674 | 1681 | | |
1675 | 1682 | | |
1676 | 1683 | | |
1677 | | - | |
| 1684 | + | |
| 1685 | + | |
1678 | 1686 | | |
1679 | | - | |
| 1687 | + | |
| 1688 | + | |
| 1689 | + | |
| 1690 | + | |
| 1691 | + | |
| 1692 | + | |
| 1693 | + | |
1680 | 1694 | | |
1681 | 1695 | | |
1682 | 1696 | | |
| |||
1738 | 1752 | | |
1739 | 1753 | | |
1740 | 1754 | | |
1741 | | - | |
| 1755 | + | |
| 1756 | + | |
1742 | 1757 | | |
1743 | 1758 | | |
1744 | | - | |
| 1759 | + | |
| 1760 | + | |
1745 | 1761 | | |
1746 | 1762 | | |
1747 | 1763 | | |
| |||
0 commit comments