实际上我创建了一个应用程序并且它的工作正常。但是假设我调试我的应用程序,并以某种方式调试我的设备锁定。现在当我解锁我的设备崩溃并显示ANR(活动无响应)。我看看logcat,但无法从那里得到任何线索。所以请帮我解决这个问题。我的logcat如下:
03-16 16:54:46.117: E/ActivityManager(114): ANR in in.plackal.lovecyclesfree
03-16 16:54:46.117: E/ActivityManager(114): Reason: Broadcast of Intent { act=android.intent.action.SCREEN_OFF flg=0x40000000 }
03-16 16:54:46.117: E/ActivityManager(114): Load: 1.49 / 1.23 / 1.28
03-16 16:54:46.117: E/ActivityManager(114): CPU usage from 5083ms to 0ms ago:
03-16 16:54:46.117: E/ActivityManager(114): 2.5% 114/system_server: 1.5% user + 0.9% kernel / faults: 3 minor
03-16 16:54:46.117: E/ActivityManager(114): 0% 14/kondemand/0: 0% user + 0% kernel
03-16 16:54:46.117: E/ActivityManager(114): 0% 49/file-storage: 0% user + 0% kernel
03-16 16:54:46.117: E/ActivityManager(114): 0.1% 182/com.android.systemui: 0.1% user + 0% kernel
03-16 16:54:46.117: E/ActivityManager(114): 2.9% TOTAL: 2.1% user + 0.7% kernel
03-16 16:54:46.117: E/ActivityManager(114): CPU usage from 212ms to 723ms later:
03-16 16:54:46.117: E/ActivityManager(114): 7.2% 114/system_server: 1.8% user + 5.4% kernel
03-16 16:54:46.117: E/ActivityManager(114): 7.2% 130/ActivityManager: 1.8% user + 5.4% kernel
03-16 16:54:46.117: E/ActivityManager(114): 1.8% 121/SurfaceFlinger: 1.8% user + 0% kernel
03-16 16:54:46.117: E/ActivityManager(114): 1.4% 182/com.android.systemui: 1.4% user + 0% kernel
03-16 16:54:46.117: E/ActivityManager(114): 3.8% TOTAL: 1.9% user + 1.9% kernel
答案 0 :(得分:-3)
如果是的话。所以问题应该在os和其他应用程序中。 如果手机上没有重要数据,请将手机重置为出厂设置,然后重试。
如果没有。问题是在你的代码中找到。查看“OnResume”或“OnStart”等代码,以查找死锁循环或网络阻塞等等。