From 4c114c905a7cc4978b418c38e91e69d4ddfcab5e Mon Sep 17 00:00:00 2001 From: YOUR_NAME Date: Sat, 6 May 2023 09:29:51 +0800 Subject: [PATCH] fix: fix thread for ces Signed-off-by: liujiandong --- services/network_search/src/device_state_observer.cpp | 1 + services/network_search/src/network_search_handler.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/services/network_search/src/device_state_observer.cpp b/services/network_search/src/device_state_observer.cpp index 32301aea9..77e139683 100644 --- a/services/network_search/src/device_state_observer.cpp +++ b/services/network_search/src/device_state_observer.cpp @@ -41,6 +41,7 @@ void DeviceStateObserver::StartEventSubscriber(const std::shared_ptr(subscriberInfo); subscriber_->SetEventHandler(deviceStateHandler); subscriber_->InitEventMap(); diff --git a/services/network_search/src/network_search_handler.cpp b/services/network_search/src/network_search_handler.cpp index f7c85a61f..223489679 100644 --- a/services/network_search/src/network_search_handler.cpp +++ b/services/network_search/src/network_search_handler.cpp @@ -131,6 +131,7 @@ bool NetworkSearchHandler::InitOperatorName() EventFwk::MatchingSkills matchingSkills; matchingSkills.AddEvent(CommonEventSupport::COMMON_EVENT_OPERATOR_CONFIG_CHANGED); EventFwk::CommonEventSubscribeInfo subscriberInfo(matchingSkills); + subscriberInfo.SetThreadMode(EventFwk::CommonEventSubscribeInfo::COMMON); operatorName_ = std::make_shared( subscriberInfo, nsm->GetNetworkSearchState(slotId_), nsm->GetSimManager(), networkSearchManager_, slotId_); if (operatorName_ == nullptr) {