Application cannot connect to network with Android ICS

I am trying to port my Phonegap / Cordova app to Android. It works with earlier versions of the SDK, but not with the Android ICS (SDK 14). I either receive java.io.IOException: An established connection was aborted by the software in your host machineor the application loads, but cannot connect to the Internet.

I have <uses-permission android:name="android.permission.INTERNET"></uses-permission>and checked that they do not duplicate the work of adb or eclipse.exe. It also cannot connect to the Internet on external devices that also run Android 4+.

My manifest has <uses-sdk android:targetSdkVersion="14" android:minSdkVersion="7" />

I pointed in the direction of viewing the trace, which when I try to start Network Statistics, I get the error message "Problem reading xt_qtaguid network statistics for the selected device."

The answer SO <here indicates that there may be a problem with the kernel and a postback is suggested, but I don’t know how to do it or if it is done correctly. My version of Eclipse is the Eclipse SDK 3.7.2

+5
source share
1 answer

since android 4. when someone tries to do network things in the android UI Thread with a android.os.NetworkOnMainThreadException throw. maybe this is a problem?

+1
source

All Articles