JSON错误" org.json.JSONException:结束输入在&QUOT字符0;字符、错误、结束、QUOT

2023-09-05 02:50:06 作者:旧梦离裳

我得到一些信息,Facebook的API,我将与Json.But运行程序我收到的时候分析 org.json.JSONException:输入的字符0结束错误。当我调试我看到错误的请求来响应。

I get some information facebook api and i will parse with Json.But when run the program i am getting org.json.JSONException: End of input at character 0 of error. When i debug i see "Bad Request" to response.

你有什么想法?

推荐答案

你可能得到一个空白的响应。它不为空,但反应是空的。所以,你得到这个错误,而不是一个空指针异常。

You are probably getting a blank response. Its not null but the response is empty. So you are getting this error and not a Nullpointer exception.

检查一些代理问题。是URL暴露在互联网上?

check for some proxy issues. Is the url exposed on the internet?