Java tutorial
//package com.java2s; //License from project: Open Source License import android.os.Build; public class Main { @SuppressWarnings("deprecation") protected static void disableConnectionReuseIfNecessary() { // HTTP connection reuse which was buggy pre-froyo if (Integer.parseInt(Build.VERSION.SDK) < Build.VERSION_CODES.FROYO) { System.setProperty("http.keepAlive", "false"); } } }