代码拉取完成,页面将自动刷新
同步操作将从 src-openEuler/distributedhardware_device_manager 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
From 62b2759508a22df2ce28dea46a20e8f87bf46337 Mon Sep 17 00:00:00 2001
From: tianhang <tian_hang@hoperun.com>
Date: Tue, 26 Sep 2023 13:42:14 +0800
Subject: [PATCH] only support network coap
---
.../src/dependency/softbus/softbus_connector.cpp | 2 +-
services/service/src/softbus/softbus_listener.cpp | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/services/implementation/src/dependency/softbus/softbus_connector.cpp b/services/implementation/src/dependency/softbus/softbus_connector.cpp
index 6640fff..4c655e2 100644
--- a/services/implementation/src/dependency/softbus/softbus_connector.cpp
+++ b/services/implementation/src/dependency/softbus/softbus_connector.cpp
@@ -135,7 +135,7 @@ int32_t SoftbusConnector::PublishDiscovery(const DmPublishInfo &dmPublishInfo)
(void)memset_s(&publishInfo, sizeof(PublishInfo), 0, sizeof(PublishInfo));
publishInfo.publishId = dmPublishInfo.publishId;
publishInfo.mode = (DiscoverMode)dmPublishInfo.mode;
- publishInfo.medium = ExchangeMedium::AUTO;
+ publishInfo.medium = ExchangeMedium::COAP;
publishInfo.freq = (ExchangeFreq)dmPublishInfo.freq;
publishInfo.capability = DM_CAPABILITY_OSD;
publishInfo.ranging = dmPublishInfo.ranging;
diff --git a/services/service/src/softbus/softbus_listener.cpp b/services/service/src/softbus/softbus_listener.cpp
index b882271..b4d36b5 100644
--- a/services/service/src/softbus/softbus_listener.cpp
+++ b/services/service/src/softbus/softbus_listener.cpp
@@ -100,7 +100,7 @@ void SoftbusListener::SetPublishInfo(PublishInfo &dmPublishInfo)
{
dmPublishInfo.publishId = DISTRIBUTED_HARDWARE_DEVICEMANAGER_SA_ID;
dmPublishInfo.mode = DiscoverMode::DISCOVER_MODE_ACTIVE;
- dmPublishInfo.medium = ExchangeMedium::AUTO;
+ dmPublishInfo.medium = ExchangeMedium::COAP;
dmPublishInfo.freq = ExchangeFreq::HIGH;
dmPublishInfo.capability = DM_CAPABILITY_OSD;
dmPublishInfo.ranging = false;
@@ -288,7 +288,7 @@ void SoftbusListener::OnParameterChgCallback(const char *key, const char *value,
(void)memset_s(&dmPublishInfo, sizeof(PublishInfo), 0, sizeof(PublishInfo));
dmPublishInfo.publishId = DISTRIBUTED_HARDWARE_DEVICEMANAGER_SA_ID;
dmPublishInfo.mode = DiscoverMode::DISCOVER_MODE_ACTIVE;
- dmPublishInfo.medium = ExchangeMedium::AUTO;
+ dmPublishInfo.medium = ExchangeMedium::COAP;
dmPublishInfo.freq = ExchangeFreq::HIGH;
dmPublishInfo.capability = DM_CAPABILITY_OSD;
dmPublishInfo.ranging = false;
@@ -331,4 +331,4 @@ void SoftbusListener::OnSoftbusDeviceInfoChanged(NodeBasicInfoType type, NodeBas
LOGD("SoftbusListener::OnSoftbusDeviceInfoChanged.");
}
} // namespace DistributedHardware
-} // namespace OHOS
\ No newline at end of file
+} // namespace OHOS
--
2.33.0
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。