From 7eef3a6f534f4b15da2bd053976671c3027f1a46 Mon Sep 17 00:00:00 2001 From: s30044129 Date: Mon, 1 Sep 2025 09:44:59 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E9=97=AE=E9=A2=98=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: s30044129 --- .../implementation/include/authentication_v2/dm_auth_state.h | 4 ++-- .../src/authentication_v2/auth_stages/auth_confirm.cpp | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/services/implementation/include/authentication_v2/dm_auth_state.h b/services/implementation/include/authentication_v2/dm_auth_state.h index f1857b8f1..4a241b935 100644 --- a/services/implementation/include/authentication_v2/dm_auth_state.h +++ b/services/implementation/include/authentication_v2/dm_auth_state.h @@ -201,7 +201,7 @@ protected: class AuthSrcConfirmState : public DmAuthState { public: - virtual ~AuthSrcConfirmState() {}; + virtual ~AuthSrcConfirmState(); DmAuthStateType GetStateType() override; int32_t Action(std::shared_ptr context) override; private: @@ -239,7 +239,7 @@ private: void GetCustomDescBySinkLanguage(std::shared_ptr context); void ResetBindLevel(std::shared_ptr context); void NegotiateUltrasonic(std::shared_ptr context); - void GenerateCertificate(std::shared_ptr context); + static void GenerateCertificate(std::shared_ptr context); }; class AuthSinkStatePinAuthComm { diff --git a/services/implementation/src/authentication_v2/auth_stages/auth_confirm.cpp b/services/implementation/src/authentication_v2/auth_stages/auth_confirm.cpp index 654139702..aa00ab7b6 100644 --- a/services/implementation/src/authentication_v2/auth_stages/auth_confirm.cpp +++ b/services/implementation/src/authentication_v2/auth_stages/auth_confirm.cpp @@ -53,6 +53,11 @@ static std::map g_pinAuthTypeFallBackMap = { // Maximum number of recursive lookups constexpr size_t MAX_FALLBACK_LOOPKUP_TIMES = 2; +AuthSrcConfirmState::AuthSrcConfirmState() +{ + LOGI("AuthSrcConfirmState destructor."); +} + DmAuthStateType AuthSrcConfirmState::GetStateType() { return DmAuthStateType::AUTH_SRC_CONFIRM_STATE; -- Gitee From 4163c365d5ef927b172bf8399eae977405ba60fe Mon Sep 17 00:00:00 2001 From: s30044129 Date: Mon, 1 Sep 2025 09:48:10 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: s30044129 --- .../src/authentication_v2/auth_stages/auth_confirm.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/implementation/src/authentication_v2/auth_stages/auth_confirm.cpp b/services/implementation/src/authentication_v2/auth_stages/auth_confirm.cpp index aa00ab7b6..ddd593d10 100644 --- a/services/implementation/src/authentication_v2/auth_stages/auth_confirm.cpp +++ b/services/implementation/src/authentication_v2/auth_stages/auth_confirm.cpp @@ -53,7 +53,7 @@ static std::map g_pinAuthTypeFallBackMap = { // Maximum number of recursive lookups constexpr size_t MAX_FALLBACK_LOOPKUP_TIMES = 2; -AuthSrcConfirmState::AuthSrcConfirmState() +AuthSrcConfirmState::~AuthSrcConfirmState() { LOGI("AuthSrcConfirmState destructor."); } -- Gitee From afa088177b440944318d1e41cf2c17b2763ce10c Mon Sep 17 00:00:00 2001 From: s30044129 Date: Mon, 1 Sep 2025 10:22:42 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: s30044129 --- interfaces/kits/js4.0/src/native_devicemanager_js.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/interfaces/kits/js4.0/src/native_devicemanager_js.cpp b/interfaces/kits/js4.0/src/native_devicemanager_js.cpp index f50d25750..8067c3066 100644 --- a/interfaces/kits/js4.0/src/native_devicemanager_js.cpp +++ b/interfaces/kits/js4.0/src/native_devicemanager_js.cpp @@ -50,7 +50,7 @@ namespace { const std::string DM_NAPI_EVENT_DEVICE_STATE_CHANGE = "deviceStateChange"; const std::string DM_NAPI_EVENT_DEVICE_DISCOVER_SUCCESS = "discoverSuccess"; -const std::string DM_NAPI_EVENT_DEVICE_DISCOVER_FAIL = "discoverFail"; +const std::string DM_NAPI_EVENT_DEVICE_DISCOVER_FAIL = "discoverFailure"; const std::string DM_NAPI_EVENT_DEVICE_PUBLISH_SUCCESS = "publishSuccess"; const std::string DM_NAPI_EVENT_DEVICE_PUBLISH_FAIL = "publishFail"; const std::string DM_NAPI_EVENT_DEVICE_SERVICE_DIE = "serviceDie"; -- Gitee From 2039def0eda8dc6fd85a670f28d214a0213de0d0 Mon Sep 17 00:00:00 2001 From: s30044129 Date: Mon, 1 Sep 2025 17:07:07 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: s30044129 --- interfaces/kits/js4.0/src/native_devicemanager_js.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/interfaces/kits/js4.0/src/native_devicemanager_js.cpp b/interfaces/kits/js4.0/src/native_devicemanager_js.cpp index 8067c3066..cdd18f78c 100644 --- a/interfaces/kits/js4.0/src/native_devicemanager_js.cpp +++ b/interfaces/kits/js4.0/src/native_devicemanager_js.cpp @@ -677,7 +677,7 @@ void DeviceManagerNapi::OnDiscoveryFailed(uint16_t subscribeId, int32_t failedRe SetValueInt32(env_, "reason", (int)failedReason, result); std::string errCodeInfo = OHOS::DistributedHardware::GetErrorString((int)failedReason); SetValueUtf8String(env_, "errInfo", errCodeInfo, result); - OnEvent("discoverFail", DM_NAPI_ARGS_ONE, &result); + OnEvent("discoverFailure", DM_NAPI_ARGS_ONE, &result); napi_close_handle_scope(env_, scope); } -- Gitee