I am using using following code to download the file form receptive source
private InputStream downloadUrl(String urlString) throws IOException {
URL url = new URL(urlString);
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
conn.setReadTimeout(10000 /* milliseconds */);
conn.setConnectTimeout(15000 /* milliseconds */);
conn.setRequestMethod("GET");
conn.setDoInput(true);
// Starts the query
Log.v("Start Query", "Stream");
conn.connect();
Log.v("End Query", "Stream");
InputStream stream = conn.getInputStream();
Log.v(stream.toString(), "Stream");
return stream;
}
I got following erros in log
11-09 12:39:59.386: D/SntpClient(73): request time failed: java.net.SocketException: Address family not supported by protocol