FixMe: Disable freeing the handler - there is a pointer ref counter not valid when doing so

pull/274/head
Olivier Martin 2024-03-29 00:17:50 +01:00
parent db629448fd
commit 6cdbe58e7b
1 changed files with 5 additions and 4 deletions

View File

@ -309,10 +309,11 @@ void gattlib_connection_free(gatt_connection_t* connection) {
disconnect_all_notifications(conn_context);
// Free all handler
gattlib_handler_free(&connection->on_connection);
gattlib_handler_free(&connection->on_disconnection);
gattlib_handler_free(&connection->indication);
gattlib_handler_free(&connection->notification);
//TODO: Fixme - there is a memory leak by not freeing the handlers
//gattlib_handler_free(&connection->on_connection);
//gattlib_handler_free(&connection->on_disconnection);
//gattlib_handler_free(&connection->indication);
//gattlib_handler_free(&connection->notification);
// Note: We do not free adapter as it might still be used by other devices