JSONデータの解析中にこの例外が発生しました:
org.apache.http.MalformedChunkCodingException: チャンク ストリームが予期せず終了しました
org.apache.http.impl.io.ChunkedInputStream.getChunkSize で
誰でも私に何をすべきかを提案できますか...私はストリームAsを読んでいます:
HttpPost request = new HttpPost(url);
StringBuilder sb=new StringBuilder();
request.getParams().setParameter(CoreProtocolPNames.USE_EXPECT_CONTINUE, Boolean.FALSE);
request.setHeader("Accept", "application/json");
HttpResponse response =null;
DefaultHttpClient httpClient = new DefaultHttpClient();
//DefaultHttpClient httpClient = getNewHttpClient();
HttpConnectionParams.setSoTimeout(httpClient.getParams(), timeOut);
HttpConnectionParams.setConnectionTimeout(httpClient.getParams(),timeOut);
response = httpClient.execute(request);
InputStream in = response.getEntity().getContent();
BufferedReader reader = new BufferedReader(new InputStreamReader(in));
String line = null;
while((line = reader.readLine()) != null){
sb.append(line);
}
resultString = sb.toString();