Search Issue Tracker
Not Reproducible
Votes
0
Found in
Issue ID
1091891
Regression
No
[Android] Hard crash in touch code
Migrated bug from GitHub: https://github.com/Unity-Technologies/InputSystem/issues/161
Forum thread here: https://forum.unity.com/threads/the-android-is-crash-when-i-using-the-new-input-system.538840/
renaldasrep commented on Jul 9
Some additional info from the user:
1. This crash is not consistently. It happen sometime when I control the UGUI joystick.
2. I am using the Unity2018b9 when the crash happen.
3. I am using the InputSystem download from the github, I think it the newest version.
4. In fact I think the device is the problem, because it not happen on real android device, but on the simulator on windows. I am using this one: http://syzs.qq.com/?ADTAG=baidu.pz.bt04_1
I think because it using the x86 code, maybe it is where the problem come from.
rotter commented on Aug 21 •
I am getting thousands of ANRs in production which MAY be related to this crash. I was gonna open a new issue but found this one and they may be related. Let me paste the stack trace, if you think it's unrelated let me know and I will open a new issue.
#00 pc 0000000000039824 /system/lib/libc.so (nanosleep+12)
#1 pc 0000000000a736dc /data/app/mygamepackage-1/lib/arm/libunity.so (???)
#2 pc 00000000002e6034 /data/app/mygamepackage-1/lib/arm/libunity.so (???)
#3 pc 0000000000462294 /data/app/mygamepackage-1/lib/arm/libunity.so (???)
#4 pc 0000000000461d90 /data/app/mygamepackage-1/lib/arm/libunity.so (???)
#5 pc 0000000000441874 /data/app/mygamepackage-1/lib/arm/libunity.so (???)
#6 pc 0000000000442e20 /data/app/mygamepackage-1/lib/arm/libunity.so (???)
#7 pc 00000000004fec37 /data/dalvik-cache/arm/data@app@mygamepackage-1@base.apk@classes.dex (Java_com_unity3d_player_UnityPlayer_nativeInjectEvent__Landroid_view_InputEvent_2+102)
at com.unity3d.player.UnityPlayer.nativeInjectEvent (Native method)
at com.unity3d.player.UnityPlayer.injectEvent (unavailable)
at com.unity3d.player.UnityPlayer.onTouchEvent (unavailable)
at android.view.View.dispatchTouchEvent (View.java:8725)
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: 40. Wait queue head age: 5507.8ms.)
in mygamepackage.myactivity
From the last 7 days:
ANRs reports: 503
Impacted users: 230
Last reported: 52 minutes ago
rotter commented on Aug 29
@Rene-Damm I am going to the airport in 3h and will be out of country without my computer for 2 weeks, so if possible please send me more requests/questions on the next few hours (if we're lucky you're Europe or Asia based).
I do have the stack traces on Google Play Console for all the other threads, but there are dozens of threads, so I will focus on threads I found with Unity on their name. Unfortunately there's no option to easily export the stack trace on GPC, so I have to copy/paste for each thread.
Motorola Moto E with 4G LTE (2nd Gen) (surnia_udstv), Android 6.0
"main" prio=5 tid=1 Native
| group="main" sCount=1 dsCount=0 obj=0x74996f98 self=0xb7bf4c60
| sysTid=29506 nice=-4 cgrp=default sched=0/0 handle=0xb6f20b34
| state=R schedstat=( 19197982750 6189377895 53625 ) utm=1399 stm=520 core=2 HZ=100
| stack=0xbe0eb000-0xbe0ed000 stackSize=8MB
| held mutexes=
#00 pc 000000000004455c /system/lib/libc.so (nanosleep+12)
#01 pc 0000000000a736dc /data/app/mygamepackage-2/lib/arm/libunity.so (???)
#02 pc 00000000002e6034 /data/app/mygamepackage-2/lib/arm/libunity.so (???)
#03 pc 0000000000462214 /data/app/mygamepackage-2/lib/arm/libunity.so (???)
#04 pc 0000000000461d90 /data/app/mygamepackage-2/lib/arm/libunity.so (???)
#05 pc 0000000000441874 /data/app/mygamepackage-2/lib/arm/libunity.so (???)
#06 pc 0000000000442e20 /data/app/mygamepackage-2/lib/arm/libunity.so (???)
#07 pc 0000000000538e35 /data/app/mygamepackage-2/oat/arm/base.odex (Java_com_unity3d_player_UnityPlayer_nativeInjectEvent__Landroid_view_InputEvent_2+96)
at com.unity3d.player.UnityPlayer.nativeInjectEvent (Native method)
at com.unity3d.player.UnityPlayer.injectEvent (unavailable)
at com.unity3d.player.UnityPlayer.onTouchEvent (unavailable)
at android.view.View.dispatchTouchEvent (View.java:9297)
at android.view.ViewGroup.dispatchTransformedTouchEvent (ViewGroup.java:2549)
at android.view.ViewGroup.dispatchTouchEvent (ViewGroup.java:2240)
at android.view.ViewGroup.dispatchTransformedTouchEvent (ViewGroup.java:2555)
at android.view.ViewGroup.dispatchTouchEvent (ViewGroup.java:2254)
at android.view.ViewGroup.dispatchTransformedTouchEvent (ViewGroup.java:2555)
at android.view.ViewGroup.dispatchTouchEvent (ViewGroup.java:2254)
at android.view.ViewGroup.dispatchTransformedTouchEvent (ViewGroup.java:2555)
at android.view.ViewGroup.dispatchTouchEvent (ViewGroup.java:2254)
at com.android.internal.policy.PhoneWindow$DecorView.superDispatchTouchEvent (PhoneWindow.java:2403)
at com.android.internal.policy.PhoneWindow.superDispatchTouchEvent (PhoneWindow.java:1737)
at android.app.Activity.dispatchTouchEvent (Activity.java:2769)
at com.android.internal.policy.PhoneWindow$DecorView.dispatchTouchEvent (PhoneWindow.java:2364)
at android.view.View.dispatchPointerEvent (View.java:9517)
at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent (ViewRootImpl.java:4242)
at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess (ViewRootImpl.java:4108)
at android.view.ViewRootImpl$InputStage.deliver (ViewRootImpl.java:3654)
at android.view.ViewRootImpl$InputStage.onDeliverToNext (ViewRootImpl.java:3707)
at android.view.ViewRootImpl$InputStage.forward (ViewRootImpl.java:3673)
at android.view.ViewRootImpl$AsyncInputStage.forward (ViewRootImpl.java:3799)
at android.view.ViewRootImpl$InputStage.apply (ViewRootImpl.java:3681)
at android.view.ViewRootImpl$AsyncInputStage.apply (ViewRootImpl.java:3856)
at android.view.ViewRootImpl$InputStage.deliver (ViewRootImpl.java:3654)
at android.view.ViewRootImpl$InputStage.onDeliverToNext (ViewRootImpl.java:3707)
at android.view.ViewRootImpl$InputStage.forward (ViewRootImpl.java:3673)
at android.view.ViewRootImpl$InputStage.apply (ViewRootImpl.java:3681)
at android.view.ViewRootImpl$InputStage.deliver (ViewRootImpl.java:3654)
at android.view.ViewRootImpl.deliverInputEvent (ViewRootImpl.java:5969)
at android.view.ViewRootImpl.doProcessInputEvents (ViewRootImpl.java:5908)
at android.view.ViewRootImpl.enqueueInputEvent (ViewRootImpl.java:5869)
at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent (ViewRootImpl.java:6072)
at android.view.InputEventReceiver.dispatchInputEvent (InputEventReceiver.java:192)
at android.view.InputEventReceiver.nativeConsumeBatchedInputEvents (Native method)
at android.view.InputEventReceiver.consumeBatchedInputEvents (InputEventReceiver.java:183)
at android.view.ViewRootImpl.doConsumeBatchedInput (ViewRootImpl.java:6043)
at android.view.ViewRootImpl$ConsumeBatchedInputRunnable.run (ViewRootImpl.java:6095)
at android.view.Choreographer$CallbackRecord.run (Choreographer.java:858)
at android.view.Choreographer.doCallbacks (Choreographer.java:670)
at android.view.Choreographer.doFrame (Choreographer.java:600)
at android.view.Choreographer$FrameDisplayEventReceiver.run (Choreographer.java:844)
at android.os.Handler.handleCallback (Handler.java:746)
at android.os.Handler.dispatchMessage (Handler.java:95)
at android.os.Looper.loop (Looper.java:148)
at android.app.ActivityThread.main (ActivityThread.java:5443)
at java.lang.reflect.Method.invoke! (Native method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:728)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:618)
"UnityMain" prio=5 tid=15 Native
| group="main" sCount=1 dsCount=0 obj=0x12cc66d0 self=0xb8bb5640
| sysTid=29539 nice=0 cgrp=default sched=0/0 handle=0xa30de930
| state=S schedstat=( 93862311063 26707217375 166733 ) utm=8426 stm=960 core=2 HZ=100
| stack=0xa2fdc000-0xa2fde000 stackSize=1038KB
| held mutexes=
#00 pc 0000000000016a6c /system/lib/libc.so (syscall+28)
#1 pc 00000000000f60bb /system/lib/libart.so (_ZN3art17ConditionVariable4WaitEPNS_6ThreadE+82)
#2 pc 000000000027e42b /system/lib/libart.so (_ZN3art3JNI14PushLocalFrameEP7_JNIEnvi+634)
#3 pc 0000000000b71bf8 /data/app/mygamepackage-2/lib/arm/libunity.so (???)
at com.unity3d.player.UnityPlayer.nativeRender (Native method)
at com.unity3d.player.UnityPlayer.c (unavailable)
at com.unity3d.player.UnityPlayer$e$2.queueIdle (unavailable)
at android.os.MessageQueue.next (MessageQueue.java:392)
at android.os.Looper.loop (Looper.java:135)
at com.unity3d.player.UnityPlayer$e.run (unavailable)
"UnityChoreographer" prio=5 tid=17 Native
| group="main" sCount=1 dsCount=0 obj=0x12d69e20 self=0xb9d15a40
| sysTid=29831 nice=-2 cgrp=default sched=0/0 handle=0x9eea1930
| state=S schedstat=( 23166704951 6635606457 51721 ) utm=1690 stm=626 core=2 HZ=100
| stack=0x9ed9f000-0x9eda1000 stackSize=1038KB
| held mutexes=
#00 pc 0000000000016a6c /system/lib/libc.so (syscall+28)
#1 pc 00000000000f60bb /system/lib/libart.so (_ZN3art17ConditionVariable4WaitEPNS_6ThreadE+82)
#2 pc 0000000000284619 /system/lib/libart.so (_ZN3art3JNI16CallObjectMethodEP7_JNIEnvP8_jobjectP10_jmethodIDz+624)
#3 pc 0000000000002bc3 /system/lib/libnativehelper.so (jniGetReferent+94)
#4 pc 000000000007735b /system/lib/libandroid_runtime.so (_ZN7android26NativeDisplayEventReceiver13dispatchVsyncExij+26)
#5 pc 000000000007757d /system/lib/libandroid_runtime.so (_ZN7android26NativeDisplayEventReceiver11handleEventEiiPv+80)
#6 pc 0000000000012f4f /system/lib/libutils.so (_ZN7android6Looper9pollInnerEi+530)
#7 pc 000000000001301f /system/lib/libutils.so (_ZN7android6Looper8pollOnceEiPiS1_PPv+130)
#8 pc 0000000000083415 /system/lib/libandroid_runtime.so (_ZN7android18NativeMessageQueue8pollOnceEP7_JNIEnvP8_jobjecti+22)
#9 pc 0000000000000585 /system/framework/arm/boot.oat (Java_android_os_MessageQueue_nativePollOnce__JI+96)
at android.os.MessageQueue.nativePollOnce (Native method)
at android.os.MessageQueue.next (MessageQueue.java:323)
at android.os.Looper.loop (Looper.java:135)
at android.os.HandlerThread.run (HandlerThread.java:61)
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Errors are logged when importing an asset at a path with Firebase
- Entering too big of a number in 2D Renderer Lightmode Tags freezes the Editor
- Crash on GUIManager::DoGUIEvent when focusing on the Game view window on a specific project
- Asset creation in the Project Browser is not always undone/inconsistent when the undo shortcut is pressed right after creating an asset
- JobTempAlloc memory leak warning is thrown when the Player is shut down
Add comment