From cbd953a27bee258a2114be30fd5a3b9dae14a993 Mon Sep 17 00:00:00 2001 From: zhouyongfei Date: Thu, 17 Feb 2022 11:55:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=B8=BB=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E4=B8=8B=E4=B8=8D=E7=94=A8=E9=94=80=E6=AF=81service=E7=9A=84bu?= =?UTF-8?q?g?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zhouyongfei --- services/src/input_method_system_ability.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/src/input_method_system_ability.cpp b/services/src/input_method_system_ability.cpp index c593627..2d59c93 100644 --- a/services/src/input_method_system_ability.cpp +++ b/services/src/input_method_system_ability.cpp @@ -547,9 +547,7 @@ namespace MiscServices { IMSA_HILOGE("Aborted! %s\n", ErrorCode::ToString(ErrorCode::ERROR_BAD_PARAMETERS)); return ErrorCode::ERROR_BAD_PARAMETERS; } - std::string defaultIme = ParaHandle::GetDefaultIme(userId_); - StopInputService(defaultIme); int32_t userId = msg->msgContent_->ReadInt32(); userId_ = userId; IMSA_HILOGI("InputMethodSystemAbility::OnUserStarted userId = %{public}u", userId); @@ -560,6 +558,8 @@ namespace MiscServices { return ErrorCode::ERROR_USER_ALREADY_STARTED; } + StopInputService(defaultIme); + setting = new PerUserSetting(userId); setting->Initialize(); PerUserSession *session = new PerUserSession(userId);