java.net.socketexception: The operation timed out problem in android?

前端 未结 2 1569
轮回少年
轮回少年 2020-12-11 06:24

In my application i wrote code for connecting to the URL like below

InputStream inputStream = new URL(url).openStream();    

i got the erro

2条回答
  •  醉话见心
    2020-12-11 07:01

    Also, I had the case that you are passing a wrong url, and the app is looking to retrieve the data, but never finds it. Check your url, maybe if you correct it, just in case that it would be wrong, then the request would not throws you that error.

提交回复
热议问题