Today in the configuration of an Android project, after running to the registration function, the information is completed, but it does not prompt registration success, the following report this mistake, very strange, read a lot of tutorials can not answer, hope friends come to answer!
D/RegisterActivity: clicked the register button
D/NetworkSecurityConfig: Using Network Security Config from resource network_security_config debugBuild: true
W/ample.dontscar: Accessing hidden method Ldalvik/system/CloseGuard; -> get()Ldalvik/system/CloseGuard; (greylist,core-platform-api, reflection, allowed)
W/ample.dontscar: Accessing hidden method Ldalvik/system/CloseGuard; -> open(Ljava/lang/String;) V(greylist,core-platform-api, reflection, allowed)
W/ample.dontscar: Accessing hidden method Ldalvik/system/CloseGuard; -> warnIfOpen()V(greylist,core-platform-api, reflection, allowed)
I/System.out:** failed to connect to /119.29.162.56(port 8080) from /10.0.2.15(port 50200) after 10000ms**
1. Disable the firewall
2. Change the ip address to
3. The mobile phone test terminal and the computer terminal are connected under the same WiFi.
0 Answer
Try this in AndroidManifest.xml < Add the following attribute under the application tag
android:networkSecurityConfig="@xml/network_security_config"
new file < br / >
< div class = "aw - list - img >
<network-security-config>
<base-config cleartextTrafficPermitted="true" />
network-security-config>
这家伙很懒,什么都没留下...