2
0
mirror of https://github.com/KDE/kdeconnect-android synced 2025-08-30 21:55:10 +00:00

Socket can't be null

This commit is contained in:
Albert Vaca
2016-06-21 13:39:55 +02:00
parent f6c4084746
commit fec0b34330

View File

@@ -67,20 +67,12 @@ public class LanLink extends BaseLink {
@Override
public void disconnect() {
Log.i("LanLink/Disconnect","socket:"+ socket.hashCode());
if (socket == null) {
Log.w("KDE/LanLink", "Not yet connected");
return;
}
try {
socket.close();
} catch (IOException e) {
e.printStackTrace();
}
}
//Returns the old socket