解决因有线连接没有指定网卡造成的VPN崩溃问题
This commit is contained in:
parent
268b3fe4df
commit
43df804cab
|
@ -194,9 +194,11 @@ void KyConnectResourse::getVpnAndVirtualConnections(QList<KyConnectItem *> &conn
|
|||
}
|
||||
NetworkManager::Device::Ptr devicePtr = nullptr;
|
||||
devicePtr = m_networkResourceInstance->findDeviceInterface(connectPtr->settings()->interfaceName());
|
||||
if (NetworkManager::ConnectionSettings::ConnectionType::Wired == connectPtr->settings()->connectionType() && !devicePtr->udi().startsWith("/sys/devices/virtual/net")) {
|
||||
if (NetworkManager::ConnectionSettings::ConnectionType::Wired == connectPtr->settings()->connectionType()) {
|
||||
if (devicePtr == nullptr || !devicePtr->udi().startsWith("/sys/devices/virtual/net")) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
QString devName = "";
|
||||
if (!devicePtr.isNull()) {
|
||||
devName = devicePtr->interfaceName();
|
||||
|
|
Loading…
Reference in New Issue