From efc82b730863588e4b45a845540c763a23297d73 Mon Sep 17 00:00:00 2001 From: Matthias Ringwald Date: Wed, 19 Jun 2019 10:46:22 +0200 Subject: [PATCH] mesh: only restart timer if there are transitions active --- test/mesh/mesh_access.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/mesh/mesh_access.c b/test/mesh/mesh_access.c index 1bc8a225c..f76a2e035 100644 --- a/test/mesh/mesh_access.c +++ b/test/mesh/mesh_access.c @@ -168,6 +168,8 @@ void mesh_access_transitions_timeout_handler(btstack_timer_source_t * timer){ break; } } + if (btstack_linked_list_empty(&transitions)) return; + btstack_run_loop_set_timer(timer, mesh_access_get_min_transitions_timeout_ms()); btstack_run_loop_add_timer(timer); }