Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

【ANR】Input dispatching timed out #59

Open
Harreke opened this issue Dec 20, 2019 · 2 comments
Open

【ANR】Input dispatching timed out #59

Harreke opened this issue Dec 20, 2019 · 2 comments

Comments

@Harreke
Copy link

Harreke commented Dec 20, 2019

库版本:v1.1.0
系统版本:Android 5.0.2 API 21
手机型号:小米 MI 2S
问题详情、异常提示:

Input dispatching timed out

ANR Input dispatching timed out (Waiting to send non-key event because the touched window has not finished processing certain input events that were delivered to it over 500.0ms ago. Wait queue length: 15. Wait queue head age: 5595.4ms.)
1 java.lang.Object.wait(Native Method)
2 java.lang.ProcessManager$ProcessImpl.waitFor(ProcessManager.java:296)
3 com.lahm.library.CommandUtil.exec(CommandUtil.java:53)
4 com.lahm.library.EmulatorCheckUtil.readSysProperty(EmulatorCheckUtil.java:71)
5 com.lahm.library.EasyProtectorLib.checkIsRunningInEmulator(EasyProtectorLib.java:66)

app启动的时候,在application中进行初始化及检测
部分机型出现了一直卡检测的问题,卡在 process.waitFor() 处迟迟无法得到检测结果,目前还不清楚原因是什么
或许是装了非官方的rom,屏蔽掉了系统sh?

可否对 CommandUtil.exec() 增加一个超时中断功能?

@lamster2018
Copy link
Owner

也不报crash?就直接ANR了?是这个意思么?

@lamster2018
Copy link
Owner

lamster2018 commented Dec 23, 2019

你如果着急解决这部分的anr问题,参考一下这个
https://my.oschina.net/u/220934/blog/303867

或者

https://janche.github.io/2019/06/16/Runtime-%E8%B0%83%E7%94%A8Process-waitfor%E5%AF%BC%E8%87%B4%E7%9A%84%E9%98%BB%E5%A1%9E%E9%97%AE%E9%A2%98/

如果有效果也及时反馈一下,我现在就算加进去了,我没有机器能够复现这个问题。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants