Got a force close in my app reporting:
java.lang.ClassCastException: int[] cannot be cast to java.lang.ref.WeakReference at android.media.SoundPool.postEventFromNative(SoundPool.java:466) at dalvik.system.NativeStart.run(Native Method)
Soundpool is wrapped by a Soundmanager class I created which is used statically, i.e.:
SoundManager.getInstance();
SoundManager.initSounds(this, mApp.Sound(), mApp.Voice());
SoundManager.loadSounds();
...
SoundManager.playSound(SoundManager.SNDGAMEOVER, 1);
...
The error occurred between my main activity and another activity - not sure if it was while one instance of the second activity was closing or was opening. Its 开发者_开发知识库difficult to debug because its intermittent. Has anyone else run in to similar problems?
精彩评论