From 8394e41cf2e87f6f878f3dbcedf9241133c22930 Mon Sep 17 00:00:00 2001 From: hw-zhangliang Date: Sun, 24 Apr 2022 17:40:37 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=9A=E8=AE=BE=E5=A4=87=E9=85=8D=E7=BD=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: hw-zhangliang --- .../src/authentication/dm_auth_manager.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/services/devicemanagerservice/src/authentication/dm_auth_manager.cpp b/services/devicemanagerservice/src/authentication/dm_auth_manager.cpp index 86d31b3e7..daf0db5c5 100644 --- a/services/devicemanagerservice/src/authentication/dm_auth_manager.cpp +++ b/services/devicemanagerservice/src/authentication/dm_auth_manager.cpp @@ -677,8 +677,9 @@ std::string DmAuthManager::GenerateGroupName() char localDeviceId[DEVICE_UUID_LENGTH] = {0}; GetDevUdid(localDeviceId, DEVICE_UUID_LENGTH); std::string sLocalDeviceId = localDeviceId; - std::string groupName = authResponseContext_->targetPkgName + authResponseContext_->hostPkgName + - sLocalDeviceId.substr(0, sLocalDeviceId.size() / DEVICE_ID_HALF); + int32_t interceptLength = sLocalDeviceId.size() / DEVICE_ID_HALF; + std::string groupName = authResponseContext_->targetPkgName + sLocalDeviceId.substr(0, interceptLength) + + authResponseContext_->localDeviceId.substr(0, interceptLength); return groupName; } -- Gitee