From b7832c7f15aef48dc138b5f23b2d3434da52a201 Mon Sep 17 00:00:00 2001 From: Matthias Ringwald Date: Tue, 4 Jul 2017 15:27:27 +0200 Subject: [PATCH] btstack_run_loop: don't call btstack_run_loop_remove_timer from platform implementation --- platform/freertos/btstack_run_loop_freertos.c | 2 +- platform/posix/btstack_run_loop_posix.c | 2 +- platform/wiced/btstack_run_loop_wiced.c | 2 +- platform/windows/btstack_run_loop_windows.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/platform/freertos/btstack_run_loop_freertos.c b/platform/freertos/btstack_run_loop_freertos.c index 09f4a8400..fc89b20cd 100644 --- a/platform/freertos/btstack_run_loop_freertos.c +++ b/platform/freertos/btstack_run_loop_freertos.c @@ -192,7 +192,7 @@ static void btstack_run_loop_freertos_task(void *pvParameter){ break; } // remove timer before processing it to allow handler to re-register with run loop - btstack_run_loop_remove_timer(ts); + btstack_run_loop_freertos_remove_timer(ts); log_debug("RL: first timer %p", ts->process); ts->process(ts); } diff --git a/platform/posix/btstack_run_loop_posix.c b/platform/posix/btstack_run_loop_posix.c index 068b33520..e69daaf2c 100644 --- a/platform/posix/btstack_run_loop_posix.c +++ b/platform/posix/btstack_run_loop_posix.c @@ -224,7 +224,7 @@ static void btstack_run_loop_posix_execute(void) { log_debug("btstack_run_loop_posix_execute: process timer %p\n", ts); // remove timer before processing it to allow handler to re-register with run loop - btstack_run_loop_remove_timer(ts); + btstack_run_loop_posix_remove_timer(ts); ts->process(ts); } } diff --git a/platform/wiced/btstack_run_loop_wiced.c b/platform/wiced/btstack_run_loop_wiced.c index 2eeb79f02..c2d436c8b 100644 --- a/platform/wiced/btstack_run_loop_wiced.c +++ b/platform/wiced/btstack_run_loop_wiced.c @@ -133,7 +133,7 @@ static void btstack_run_loop_wiced_execute(void) { uint32_t now = btstack_run_loop_wiced_get_time_ms(); if (ts->timeout < now){ // remove timer before processing it to allow handler to re-register with run loop - btstack_run_loop_remove_timer(ts); + btstack_run_loop_wiced_remove_timer(ts); // printf("RL: timer %p\n", ts->process); ts->process(ts); continue; diff --git a/platform/windows/btstack_run_loop_windows.c b/platform/windows/btstack_run_loop_windows.c index 9967c7143..f9ef2c956 100644 --- a/platform/windows/btstack_run_loop_windows.c +++ b/platform/windows/btstack_run_loop_windows.c @@ -216,7 +216,7 @@ static void btstack_run_loop_windows_execute(void) { log_debug("btstack_run_loop_windows_execute: process timer %p\n", ts); // remove timer before processing it to allow handler to re-register with run loop - btstack_run_loop_remove_timer(ts); + btstack_run_loop_windows_remove_timer(ts); ts->process(ts); } }