Android emulator error: std::bad_alloc

眉间皱痕 提交于 2019-12-03 17:44:11

问题


I'm using Eclipse Juno and the Android emulator (SDK Tools 21.1) and I'm having this error a lot of times (well, two or three times in 6 hours):

[2013-03-22 11:41:19 - Emulator] terminate called after throwing an instance of 'std::bad_alloc'
[2013-03-22 11:41:19 - Emulator]   what():  std::bad_alloc
[2013-03-22 11:41:19 - Emulator] 
[2013-03-22 11:41:19 - Emulator] This application has requested the Runtime to terminate it in an      unusual way.
[2013-03-22 11:41:19 - Emulator] Please contact the application's support team for more information.

I've googled it but it seems to be an C++ error. I don't know if it's an error of my application or if is an error of Eclipse or the emulator. (The LogCat does not show any error).


回答1:


Sorry my reputation is not high enough, this should be a comment, since it is not a real solution.

I'm having the same issues, but it stops when I disable 'Use Host GPU'. I think it must be an error in of the emulator, since I can also generate the issue when I play around in the emulator (without using my own app).




回答2:


As stated by RobinDeCroon, I only have this issue when using "Use Host GPU". From Related, it's possibly a bug/problem with older Intel graphics cards




回答3:


I Had the exactly same error message while using Android Studio and Fixed it by changing the Boot option from Quick Boot to Cold Boot. In Android Studio you can go into Tools > Android > AVD Manager > Edit (The Pencil) > Show Advanced Settings > And changed from Quick Boot to Cold Boot.

I don't know how to do that only with only the emulator, but this may be a clue of how to solve this.



来源:https://stackoverflow.com/questions/15568475/android-emulator-error-stdbad-alloc

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!