!8418 fix: 保存networkid

Merge pull request !8418 from liangjunhao/master
This commit is contained in:
openharmony_ci 2024-11-21 02:31:07 +00:00 committed by Gitee
commit bb3c07fa4c
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -322,6 +322,11 @@ static int32_t AcceptUdpChannelAsServer(AppInfo *appInfo)
ReleaseUdpChannelId(appInfo->myData.channelId);
return udpPort;
}
int32_t ret = LnnGetNetworkIdByUuid(
(const char *)appInfo->peerData.deviceId, appInfo->peerNetWorkId, DEVICE_ID_SIZE_MAX);
if (ret != SOFTBUS_OK) {
TRANS_LOGE(TRANS_CTRL, "get network id by uuid failed.");
}
appInfo->myData.port = udpPort;
UdpChannelInfo *newChannel = NewUdpChannelByAppInfo(appInfo);
if (newChannel == NULL) {