need to run emulator with proxy settings , I am using the following command in command prompt to start emulator
emulator -avd AVD_for_3_7_WVGA_Nexus_One -http-proxy http://username:password@IP:Port
Without http-proxy switch it is working fine , where as using the http-proxy following error occured :
FATAL:.//android/base/sockets/SocketWaiter.cpp:89:Check failed: isValidFd(fd). fd 1404 max1024
Just to clarify: from within your app, you can simply refer to the emulator as 'localhost' or 127.0. 0.1. Web traffic is routed through your development machine, so the emulator's external IP is whatever IP has been assigned to that machine by your provider.
I'm experiencing the exact same issue.
Luckily there is a workaround and I can say it's working (at least in my case): adding the -no-audio
parameter to the command:
emulator -avd <device_name> -no-audio -http-proxy http://<username:password@>IP:Port
edit: even if it's working for you, please star the bug to get it fixed!
For some reason Android Emulator doesn't like IP address as the proxy. If you are using Fiddler use localhost:8888
:
emulator.exe -avd Nexus_5_API_21_x86 -no-audio -http-proxy localhost:8888
Don't forget -no-audio
parameter too.
Adding "-http-proxy none" (without quotes) in Run configuration also fixes this issue as shown in image attached. Please note this is one way of fixing this issue. Your app may not be able to connect to internet via proxy later on.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With