Skip to content

Commit e74df07

Browse files
sylvioalvesmarekmatej
authored andcommitted
ble: adapter: fix invalid intr handler pointer
Due to invalid pointer address, application crashes when calling ble deinit call. Signed-off-by: Sylvio Alves <[email protected]>
1 parent 82c93ea commit e74df07

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

zephyr/esp32c3/src/bt/esp_bt_adapter.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,7 @@ static inline void esp_bt_power_domain_off(void)
437437
static void btdm_intr_alloc(void *arg)
438438
{
439439
btdm_isr_alloc_t *p = arg;
440-
p->ret = esp_intr_alloc(p->source, p->flags, p->fn, p->arg, &p->handle);
440+
p->ret = esp_intr_alloc(p->source, p->flags, p->fn, p->arg, (intr_handle_t *) p->handle);
441441
}
442442

443443
static int interrupt_alloc_wrapper(int cpu_id, int source, intr_handler_t handler, void *arg, void **ret_handle)

zephyr/esp32s3/src/bt/esp_bt_adapter.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -435,7 +435,7 @@ static inline void esp_bt_power_domain_off(void)
435435
static void btdm_intr_alloc(void *arg)
436436
{
437437
btdm_isr_alloc_t *p = arg;
438-
p->ret = esp_intr_alloc(p->source, p->flags, p->fn, p->arg, &p->handle);
438+
p->ret = esp_intr_alloc(p->source, p->flags, p->fn, p->arg, (intr_handle_t *) p->handle);
439439
}
440440

441441
static int interrupt_alloc_wrapper(int cpu_id, int source, intr_handler_t handler, void *arg, void **ret_handle)

0 commit comments

Comments
 (0)