diff options
| -rw-r--r-- | supervisor/shared/background_callback.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/supervisor/shared/background_callback.c b/supervisor/shared/background_callback.c index 99607b7a8..e45c9b5c3 100644 --- a/supervisor/shared/background_callback.c +++ b/supervisor/shared/background_callback.c @@ -61,8 +61,11 @@ void background_callback_add(background_callback_t *cb, background_callback_fun static bool in_background_callback; void background_callback_run_all() { + if (!callback_head) { + return; + } CALLBACK_CRITICAL_BEGIN; - if(in_background_callback) { + if (in_background_callback) { CALLBACK_CRITICAL_END; return; } |
