From 5ead86c37c5e8f1c915ddc67448a4c2b21d9d546 Mon Sep 17 00:00:00 2001 From: etkmao Date: Fri, 22 Sep 2023 21:57:27 +0800 Subject: [PATCH] fix(core): crash protect for worker on ios --- modules/footstone/src/task_runner.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/footstone/src/task_runner.cc b/modules/footstone/src/task_runner.cc index 1b400caf319..b8a60590a26 100644 --- a/modules/footstone/src/task_runner.cc +++ b/modules/footstone/src/task_runner.cc @@ -201,7 +201,9 @@ TimeDelta TaskRunner::GetNextTimeDelta(TimePoint now) { void TaskRunner::NotifyWorker() { auto worker = worker_.lock(); - FOOTSTONE_CHECK(worker); + if (!worker) { + return; + } worker->Notify(); }