From 01610a895dbfca4a3e832bbf95117857e5b2db50 Mon Sep 17 00:00:00 2001 From: lsq Date: Mon, 11 Apr 2022 14:59:23 +0800 Subject: [PATCH] Signed-off-by: lsq Change-Id: Ife9e2c48f01694549d7cd4f71e99a909fc1402a0 --- .../src/device/device_info_manager.cpp | 6 ------ .../src/remote/remote_command_manager.cpp | 11 +++++------ .../tokensyncmanager/src/remote/soft_bus_manager.cpp | 10 ++++------ 3 files changed, 9 insertions(+), 18 deletions(-) diff --git a/services/tokensyncmanager/src/device/device_info_manager.cpp b/services/tokensyncmanager/src/device/device_info_manager.cpp index 2c21af2a1..dfe35aa9a 100644 --- a/services/tokensyncmanager/src/device/device_info_manager.cpp +++ b/services/tokensyncmanager/src/device/device_info_manager.cpp @@ -141,12 +141,6 @@ std::string DeviceInfoManager::ConvertToUniqueDeviceIdOrFetch(const std::string ACCESSTOKEN_LOG_DEBUG(LABEL, ">>> DeviceInfoRepository device network id: %{public}s", Constant::EncryptDevId(info.deviceId.networkId).c_str()); - ACCESSTOKEN_LOG_DEBUG(LABEL, - ">>> DeviceInfoRepository device udid: %{public}s", - Constant::EncryptDevId(info.deviceId.uniqueDeviceId).c_str()); - ACCESSTOKEN_LOG_DEBUG(LABEL, - ">>> DeviceInfoRepository device uuid: %{public}s", - Constant::EncryptDevId(info.deviceId.universallyUniqueId).c_str()); } } return result; diff --git a/services/tokensyncmanager/src/remote/remote_command_manager.cpp b/services/tokensyncmanager/src/remote/remote_command_manager.cpp index 2cbf1bbb5..5d119f278 100644 --- a/services/tokensyncmanager/src/remote/remote_command_manager.cpp +++ b/services/tokensyncmanager/src/remote/remote_command_manager.cpp @@ -54,11 +54,11 @@ void RemoteCommandManager::Init() int RemoteCommandManager::AddCommand(const std::string &udid, const std::shared_ptr &command) { if (udid.empty() || command == nullptr) { - ACCESSTOKEN_LOG_WARN(LABEL, "invalid udid: %{public}s, or null command", udid.c_str()); + ACCESSTOKEN_LOG_WARN(LABEL, "invalid udid, or null command"); return Constant::FAILURE; } std::string uniqueId = command->remoteProtocol_.uniqueId; - ACCESSTOKEN_LOG_INFO(LABEL, "udid: %{public}s, add uniqueId: %{public}s", udid.c_str(), uniqueId.c_str()); + ACCESSTOKEN_LOG_INFO(LABEL, "add uniqueId"); std::shared_ptr executor = GetOrCreateRemoteCommandExecutor(udid); if (executor == nullptr) { @@ -67,13 +67,13 @@ int RemoteCommandManager::AddCommand(const std::string &udid, const std::shared_ } int result = executor->AddCommand(command); - ACCESSTOKEN_LOG_INFO(LABEL, "udid: %{public}s, add command result: %{public}d ", udid.c_str(), result); + ACCESSTOKEN_LOG_INFO(LABEL, "add command result: %{public}d ", result); return result; } void RemoteCommandManager::RemoveCommand(const std::string &udid) { - ACCESSTOKEN_LOG_INFO(LABEL, "remove command, udid: %{public}s", udid.c_str()); + ACCESSTOKEN_LOG_INFO(LABEL, "remove command"); executors_.erase(udid); } @@ -269,10 +269,9 @@ std::shared_ptr RemoteCommandManager::GetExecutorChannel(const std:: { ACCESSTOKEN_LOG_DEBUG(LABEL, "convert udid start, nodeId:%{public}s", nodeId.c_str()); std::string udid = DeviceInfoManager::GetInstance().ConvertToUniqueDeviceIdOrFetch(nodeId); - ACCESSTOKEN_LOG_DEBUG(LABEL, "convert udid, nodeId:%{public}s, udid: %{public}s", nodeId.c_str(), udid.c_str()); if (!DataValidator::IsDeviceIdValid(udid)) { ACCESSTOKEN_LOG_WARN( - LABEL, "converted udid is invalid, nodeId:%{public}s, udid: %{public}s", nodeId.c_str(), udid.c_str()); + LABEL, "converted udid is invalid, nodeId:%{public}s", nodeId.c_str()); return nullptr; } std::map>::iterator iter = executors_.find(udid); diff --git a/services/tokensyncmanager/src/remote/soft_bus_manager.cpp b/services/tokensyncmanager/src/remote/soft_bus_manager.cpp index 74f466f7b..aedf422b8 100644 --- a/services/tokensyncmanager/src/remote/soft_bus_manager.cpp +++ b/services/tokensyncmanager/src/remote/soft_bus_manager.cpp @@ -171,8 +171,7 @@ int32_t SoftBusManager::OpenSession(const std::string &deviceId) int sessionId = ::OpenSession(SESSION_NAME.c_str(), SESSION_NAME.c_str(), networkId.c_str(), SESSION_GROUP_ID.c_str(), &SESSION_ATTR); - ACCESSTOKEN_LOG_DEBUG(LABEL, "session info: sessionId: %{public}d, uuid: %{public}s, udid: %{public}s", sessionId, - info.deviceId.universallyUniqueId.c_str(), info.deviceId.uniqueDeviceId.c_str()); + ACCESSTOKEN_LOG_DEBUG(LABEL, "async open session"); // wait session opening int retryTimes = 0; @@ -307,8 +306,7 @@ std::string SoftBusManager::GetUdidByNodeId(const std::string &nodeId) const } std::string udid(reinterpret_cast(info)); delete[] info; - ACCESSTOKEN_LOG_DEBUG(LABEL, "call softbus finished: nodeId(in): %{public}s, udid: %{public}s", nodeId.c_str(), - udid.c_str()); + ACCESSTOKEN_LOG_DEBUG(LABEL, "call softbus finished: nodeId(in): %{public}s", nodeId.c_str()); return udid; } @@ -341,8 +339,8 @@ int SoftBusManager::FulfillLocalDeviceInfo() DeviceInfoManager::GetInstance().AddDeviceInfo(info.networkId, uuid, udid, info.deviceName, std::to_string(info.deviceTypeId)); - ACCESSTOKEN_LOG_DEBUG(LABEL, "AddDeviceInfo finished, networkId:%{public}s, uuid:%{public}s, udid:%{public}s", - info.networkId, uuid.c_str(), udid.c_str()); + ACCESSTOKEN_LOG_DEBUG(LABEL, "AddDeviceInfo finished, networkId:%{public}s", + info.networkId); fulfillMutex_.unlock(); return Constant::SUCCESS; -- Gitee