Android crash due to Input

Recently i publish a game in the play store, some users report random crashes on android 4.3 and above, i had tested my app in several phones mostly 4.0.x with zero problems. I debug the app using the AVD and a 4.4 android device resulting in a crash, this is the log :

D/InputEventConsistencyVerifier( 2578): TouchEvent: ACTION_MOVE contained 1 pointers but there are currently 0 pointers down.
D/InputEventConsistencyVerifier( 2578): in com.android.internal.policy.impl.PhoneWindow$DecorView{b2d478a0 V.E… R…I. 0,0-288,240}
D/InputEventConsistencyVerifier( 2578): 0: sent at 53427610000000, MotionEvent { action=ACTION_MOVE, id[0]=0, x[0]=229.0, y[0]=210.0, toolType[0]=TOOL_TYPE_UNKNOWN, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=1, eventTime=53427610, downTime=53427262, deviceId=0, source=0x1002 }

In the app you control a marble, rolling it with the finger, here the code within the Update function that causes the error :

t = Input.GetTouch(0);
if (t.phase==TouchPhase.Moved)
{
    final.Set(t.deltaPosition.x, 0, t.deltaPosition.y);
    velocidad = t.deltaPosition.magnitude / t.deltaTime;//touch's speed of motion

    if (rigidbody.velocity.magnitude < maxSpeed)
    {
        rigidbody.AddForce(final * velocidad);
    }                
}

I found that replacing that code, with other approach like this solve the error :

switch (Input.GetTouch(0).phase)
    {
        case TouchPhase.Began:
            SW = false;
            startpos = new Vector3(Input.GetTouch(0).position.x, 0, Input.GetTouch(0).position.y);
            break;
        case TouchPhase.Moved:
            SW = true;
            break;
        case TouchPhase.Canceled:
            SW = false;
            return;
        case TouchPhase.Stationary:
            SW = false;
            break;
        case TouchPhase.Ended:
            if (SW)
            {
                endpos = new Vector3(Input.GetTouch(0).position.x, 0, Input.GetTouch(0).position.y);
                final = endpos - startpos;
                if (rigidbody.velocity.magnitude < maxSpeed)
                {
                    rigidbody.AddForce(final);
                }
            }
            break;
    }

With this code the apps doesnt freeze but the movement is less accurate, you must end the stroke in order to apply the force to the ball, while in the first solution the ball steadily respond your finger movements. It seems to me that the problem is the access to the Input.GetTouch(0) during the TouchPhase.Moved state in terminals with the most recent android version.

Any help would be appreciated, i spent a lot of time wondering the cause of this randomly crashes.

@sugarat I wouldn’t accept this as an answer because it really isn’t, but i would think you could replicate checking if phase == moved by recording the touch location (once the touch has started) and checking it every fixed update, if it’s different you know it’s moving, then recording the new location. you could also if it out in fixed update to only do it when you need or do something crazy like start a coroutine that just checks it, waits a fixed update, then checks again if you don’t want to be checking it every fixed update when you don’t need.

i’d love a real fix so let me know if you come across one, but hopefully that should enable you to work around and regain your full functionality…

i always figured people’s fingers would rarely be actually stationary since even adjusting the amount of surface area your finger touches the screen with would probably move it slightly, and the pixels are minuscule these days… but i’ve never tested it.