Hello everyone, 

I'm new to Android development, and I'm not sure why I'm getting this 
exception when I'm rotating the screen.

08-05 21:15:43.850: ERROR/ActivityManager(276): fail to set top app 
changed! (2)
        java.lang.NullPointerException
        at 
com.android.server.am.ActivityManagerService.handleTopAppChanged(ActivityManagerService.java:15942)
        at 
com.android.server.am.ActivityManagerService.updateOomAdjLocked(ActivityManagerService.java:15392)
        at 
com.android.server.am.ActivityManagerService.updateLruProcessInternalLocked(ActivityManagerService.java:1957)
        at 
com.android.server.am.ActivityManagerService.updateLruProcessLocked(ActivityManagerService.java:1964)
        at 
com.android.server.am.ActivityStack.resumeTopActivityLocked(ActivityStack.java:1692)
        at 
com.android.server.am.ActivityStack.finishCurrentActivityLocked(ActivityStack.java:3910)
        at 
com.android.server.am.ActivityStack.finishActivityLocked(ActivityStack.java:3841)
        at 
com.android.server.am.ActivityManagerService.forceStopPackageLocked(ActivityManagerService.java:3964)
        at 
com.android.server.am.ActivityManagerService.access$400(ActivityManagerService.java:183)
        at 
com.android.server.am.ActivityManagerService$2.handleMessage(ActivityManagerService.java:1231)
        at android.os.Handler.dispatchMessage(Handler.java:99)
        at android.os.Looper.loop(Looper.java:156)
        at 
com.android.server.am.ActivityManagerService$AThread.run(ActivityManagerService.java:1580)


You can see the code here <http://pastebin.com/03GpfSLw>. Also, I noticed 
that in the code here:
if (fragment != null) {
the fragment becomes null when the device rotates after the progress dialog 
is shown.

Thanks!

Steven

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to