This patch fixes potential cases of invalid access if discovery and MTU exchange procedure callbacks are invoked after cleaning up a bt_gatt_client, by cancelling all pending discovery and exchange MTU requests in bt_gatt_cancel_all.
c74113c shared/gatt: Cancel discovery requests in client
src/shared/gatt-client.c | 113 ++++++++++++++++++++++++++++++++++------------
1 file changed, 85 insertions(+), 28 deletions(-)
Upstream: git.kernel.org