Saturday, October 31, 2009

[android-developers] Mystery Null Pointer Error - Seeking Opinions

*,

An error that appeared in my Flurry logs but seemed impossible to reproduce otherwise just occured!  That's the good news.  The bad news is that the LogCat info is not telling me enough.  I would appreciate a second set of eyes taking a look and offering wisdom.

The lead up is that I was playing with my app, and put it away for a while.  I did a lot of other things with my phone since, like making phone calls, etc ...  I hooked up my phone to the computer to make another attempt to find the mystery bug, and decided to see if anything weird appeared in the logs from earlier.  I then brought my app to the foreground using the Home/Hold technique and whamo!  the bug appeared before my eyes in LogCat. 

I got a Force Close message.  When the app died, it did not get resurrected.  What is particularly odd is the "onPrepareOptionsMenu" being called (at all).

So here is what LogCat coughed up:

This is not my app but may provide a clue ...
-----------------------------------------------------------

10-31 14:12:02.047: INFO/WindowManager(74): onOrientationChanged, rotation changed to 0
10-31 14:12:02.117: WARN/InputManagerService(74): Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy@43422388

7369 is my app:
---------------------

10-31 14:12:02.127: DEBUG/dalvikvm(7369): Trying to load lib /system/lib/libsoundpool.so 0x0
10-31 14:12:02.677: DEBUG/dalvikvm(7369): Added shared lib /system/lib/libsoundpool.so 0x0
10-31 14:12:03.277: DEBUG/FlurryAgent(7369): Starting new session
10-31 14:12:03.657: DEBUG/AndroidRuntime(7369): Shutting down VM
10-31 14:12:03.657: WARN/dalvikvm(7369): threadid=3: thread exiting with uncaught exception (group=0x4001da28)
10-31 14:12:03.657: DEBUG/FlurryAgent(7369): Ending session
10-31 14:12:03.667: ERROR/AndroidRuntime(7369): Uncaught handler: thread main exiting due to uncaught exception

10-31 14:12:04.077: ERROR/AndroidRuntime(7369): java.lang.NullPointerException
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at com.bubblebeats.free.Peeps.onPrepareOptionsMenu(Peeps.java:377)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at android.app.Activity.onPreparePanel(Activity.java:2065)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at com.android.internal.policy.impl.PhoneWindow.preparePanel(PhoneWindow.java:429)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at com.android.internal.policy.impl.PhoneWindow.openPanel(PhoneWindow.java:517)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at com.android.internal.policy.impl.PhoneWindow.openPanelsAfterRestore(PhoneWindow.java:1590)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at com.android.internal.policy.impl.PhoneWindow.access$1500(PhoneWindow.java:86)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at com.android.internal.policy.impl.PhoneWindow$DecorView.onAttachedToWindow(PhoneWindow.java:2043)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at android.view.View.dispatchAttachedToWindow(View.java:5567)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at android.view.ViewGroup.dispatchAttachedToWindow(ViewGroup.java:1032)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at android.view.ViewRoot.performTraversals(ViewRoot.java:676)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at android.view.ViewRoot.handleMessage(ViewRoot.java:1613)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at android.os.Handler.dispatchMessage(Handler.java:99)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at android.os.Looper.loop(Looper.java:123)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at android.app.ActivityThread.main(ActivityThread.java:4203)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at java.lang.reflect.Method.invokeNative(Native Method)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at java.lang.reflect.Method.invoke(Method.java:521)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:791)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549)
10-31 14:12:04.077: ERROR/AndroidRuntime(7369):     at dalvik.system.NativeStart.main(Native Method)
10-31 14:12:04.517: DEBUG/dalvikvm(7369): GC freed 1736 objects / 111624 bytes in 248ms

Thanks for the feedback in advance.

Jason Van Anden
http://www.BubbleBeats.com

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

No comments:

Post a Comment