fix : failed to find local ip in windows

This commit is contained in:
Livox-SDK
2019-08-13 18:16:19 +08:00
parent 28280005c1
commit 7273301168
2 changed files with 49 additions and 25 deletions
+3
View File
@@ -210,6 +210,9 @@ void DeviceDiscovery::OnBroadcast(const CommPacket &packet, apr_sockaddr_t *addr
result = false;
break;
}
LOG_INFO(" LocalIP: {}", inet_ntoa(*(struct in_addr *)&local_ip));
LOG_INFO("Command Port: {}", lidar_info.cmd_port);
LOG_INFO("Data Port: {}", lidar_info.data_port);
CommPacket packet;
memset(&packet, 0, sizeof(packet));
handshake_req.ip_addr = local_ip;