facebookarchive / stetho

Stetho is a debug bridge for Android applications, enabling the powerful Chrome Developer Tools and much more.
http://facebook.github.io/stetho/
MIT License
12.66k stars 1.13k forks source link

java.lang.OutOfMemoryError: Could not allocate JNI Env #627

Closed codingBobo closed 5 years ago

codingBobo commented 5 years ago

java.lang.OutOfMemoryError: Could not allocate JNI Env at java.lang.Thread.nativeCreate(Native Method) at java.lang.Thread.start(Thread.java:729) at com.facebook.stetho.server.LocalSocketServer.listenOnAddress(LocalSocketServer.java:94) at com.facebook.stetho.server.LocalSocketServer.run(LocalSocketServer.java:74) at com.facebook.stetho.server.ServerManager$1.run(ServerManager.java:40)

I got this error on version 1.5.0,it looks like too many threads had be created。

jasta commented 5 years ago

Err, I think this may be something related to your application itself. Stetho is only creating one thread to do this socket listening.