Fixed crash when pairing old Android apps.
This commit is contained in:
parent
ebd429629a
commit
8f9fde8f40
2 changed files with 6 additions and 1 deletions
|
@ -140,6 +140,11 @@ void LanDeviceLink::userRequestsUnpair()
|
|||
|
||||
void LanDeviceLink::setPairStatus(PairStatus status)
|
||||
{
|
||||
if (status == Paired && mSocketLineReader->peerCertificate().isNull()) {
|
||||
Q_EMIT pairingError(i18n("This device can't be paired because is running an old version of KDE Connect."));
|
||||
return;
|
||||
}
|
||||
|
||||
DeviceLink::setPairStatus(status);
|
||||
if (status == Paired) {
|
||||
Q_ASSERT(KdeConnectConfig::instance()->trustedDevices().contains(deviceId()));
|
||||
|
|
|
@ -235,7 +235,7 @@ void LanLinkProvider::connected()
|
|||
return; // Return statement prevents from deleting received package, needed in slot "encrypted"
|
||||
} else {
|
||||
qWarning() << "Incompatible protocol version, this won't work";
|
||||
addLink(deviceId, socket, receivedPackage, LanDeviceLink::Remotely);
|
||||
//addLink(deviceId, socket, receivedPackage, LanDeviceLink::Remotely);
|
||||
}
|
||||
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue