Przeglądaj źródła

Merge branch 'bugfix/btdm_fix_memory_leak_in_v3.2' into 'master'

Component/bt: fix memory leak in service change char

See merge request idf/esp-idf!3631
Jiang Jiang Jian 7 lat temu
rodzic
commit
c7fb749b84
1 zmienionych plików z 2 dodań i 0 usunięć
  1. 2 0
      components/bt/bluedroid/stack/gatt/gatt_main.c

+ 2 - 0
components/bt/bluedroid/stack/gatt/gatt_main.c

@@ -188,6 +188,8 @@ void gatt_free(void)
 
 #if (GATTS_INCLUDED == TRUE)
     for (i = 0; i < GATT_MAX_SR_PROFILES; i++) {
+        gatt_remove_an_item_from_list(&gatt_cb.hdl_list_info, &gatt_cb.hdl_list[i]);
+        gatt_free_attr_value_buffer(&gatt_cb.hdl_list[i]);
         gatt_free_hdl_buffer(&gatt_cb.hdl_list[i]);
     }
 #endif /* #if (GATTS_INCLUDED == TRUE) */