Vote count:
0
I experience a problem in my android app and wonder if you know a solution. I use HttpUrlConnection and if i connect to the host myhost.local
(via http and https both is possible) everything works just fine. But if I want to connect to the host myhost
I get following exception:
java.net.UnknownHostException: Unable to resolve host
insert_host_here
: No address associated with hostname
If I use the browser on my phone both myhost.local
and my myhost
can be accessed. And if I type $ host myhost
into terminal i get following answer
user@machine:$ host myhost.local myhost.local has address 192.168.0.115 user@machine:$ host myhost myhost.local has address 192.168.0.115
There is no proxy in between or something. Its the direct answer from the dns. Some idea what it could be?
Greetz
btw: internet permission is granted / device has access to wifi / Version on tested device is Android 4.3 / Emulator shows same result
Android UnknownHostException with .local host
Aucun commentaire:
Enregistrer un commentaire