mirror of
https://github.com/moparisthebest/Conversations
synced 2024-11-30 20:52:21 -05:00
code cleanup
This commit is contained in:
parent
8988873d77
commit
592068e7cf
@ -36,17 +36,10 @@ public class DNSHelper {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (ClassNotFoundException e) {
|
} catch (Exception e) {
|
||||||
ip = InetAddress.getByName("8.8.8.8");
|
Log.d("xmppService","error during system calls");
|
||||||
} catch (NoSuchMethodException e) {
|
|
||||||
ip = InetAddress.getByName("8.8.8.8");
|
|
||||||
} catch (IllegalAccessException e) {
|
|
||||||
ip = InetAddress.getByName("8.8.8.8");
|
|
||||||
} catch (IllegalArgumentException e) {
|
|
||||||
ip = InetAddress.getByName("8.8.8.8");
|
|
||||||
} catch (InvocationTargetException e) {
|
|
||||||
ip = InetAddress.getByName("8.8.8.8");
|
|
||||||
}
|
}
|
||||||
|
ip = InetAddress.getByName("8.8.8.8");
|
||||||
return queryDNS(host, ip);
|
return queryDNS(host, ip);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -90,7 +83,6 @@ public class DNSHelper {
|
|||||||
datagramSocket.setSoTimeout(3000);
|
datagramSocket.setSoTimeout(3000);
|
||||||
datagramSocket.receive(receivePacket);
|
datagramSocket.receive(receivePacket);
|
||||||
if (receiveData[3] != -128) {
|
if (receiveData[3] != -128) {
|
||||||
Log.d("xmppService", "not the right count");
|
|
||||||
namePort.putString("error", "nosrv");
|
namePort.putString("error", "nosrv");
|
||||||
return namePort;
|
return namePort;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user