Merge branch 'bug-195043' into 'yhkylin/v101'
fix(hotspot):无线网卡热点能力判断修改(#195043) See merge request kylinos-src/kylin-nm!275
This commit is contained in:
commit
d87f99ea9f
|
@ -453,7 +453,7 @@ int KyNetworkDeviceResourse::getWirelessDeviceCapability(const QString deviceNam
|
|||
qobject_cast<NetworkManager::WirelessDevice *>(connectDevice.data());
|
||||
|
||||
int cap = 0x00;
|
||||
if (wirelessDevicePtr->wirelessCapabilities() & NetworkManager::WirelessDevice::AdhocCap) {
|
||||
if (wirelessDevicePtr->wirelessCapabilities() & NetworkManager::WirelessDevice::ApCap) {
|
||||
cap = cap | 0x02;
|
||||
} else {
|
||||
return 0x01;
|
||||
|
|
|
@ -295,6 +295,10 @@ QString KyWirelessNetResource::getDeviceIFace(NetworkManager::ActiveConnection::
|
|||
NetworkManager::Device:: Ptr devicePtr =
|
||||
m_networkResourceInstance->findDeviceUni(ifaceUni);
|
||||
|
||||
if (devicePtr.isNull()) {
|
||||
return QString();
|
||||
}
|
||||
|
||||
return devicePtr->interfaceName();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue