I am getting the above error whenever I test on an emulator, but not any devices I have tested on. Can anyone suggest why this might happen ?
Asked
Active
Viewed 791 times
1

Mohammed Azharuddin Shaikh
- 41,633
- 14
- 96
- 115

GuybrushThreepwood
- 5,598
- 9
- 55
- 113
-
3emulator heap size is low compared with real device...! – Dinesh Jun 23 '12 at 10:03
-
read this post for different android mobiles heap size http://stackoverflow.com/questions/5350465/android-heap-size-on-different-phones-and-os-versions/9940415#9940415 – Dinesh Jun 23 '12 at 10:08
-
Thank all - what's the heap size of the emulator ? – GuybrushThreepwood Jun 23 '12 at 10:14
1 Answers
3
You are probably testing on high profile devices that might have 32Mb or more heap size memory. The emulator could be using 24Mb and that's the reason is crashing.
Go to the AVD (Android Virtual Device) editor, and add "Max VM application heap size" to your virtual device hardware properties. Set that value to 32Mb and reboot your emulator.
That should be enough.
If you want to learn more about heap memory I recommend you to read this question.