-
Notifications
You must be signed in to change notification settings - Fork 814
Description
Actual Behaviour
App crashes when user plays a saved gyroscope log
Expected Behaviour
App should not crash
Steps to reproduce it
Record gyroscope data, and play it from data logger activity
LogCat for the issue
2019-06-21 22:19:31.751 17761-17761/io.pslab E/AndroidRuntime: FATAL EXCEPTION: main
Process: io.pslab, PID: 17761
java.lang.NullPointerException: Attempt to invoke virtual method 'int java.util.ArrayList.size()' on a null object reference
at io.pslab.fragment.GyroscopeDataFragment.playData(GyroscopeDataFragment.java:286)
at io.pslab.models.PSLabSensor.onOptionsItemSelected(PSLabSensor.java:339)
at android.app.Activity.onMenuItemSelected(Activity.java:3469)
at android.support.v4.app.FragmentActivity.onMenuItemSelected(FragmentActivity.java:436)
at android.support.v7.app.AppCompatActivity.onMenuItemSelected(AppCompatActivity.java:196)
at android.support.v7.view.WindowCallbackWrapper.onMenuItemSelected(WindowCallbackWrapper.java:109)
at android.support.v7.view.WindowCallbackWrapper.onMenuItemSelected(WindowCallbackWrapper.java:109)
at android.support.v7.app.ToolbarActionBar$2.onMenuItemClick(ToolbarActionBar.java:64)
at android.support.v7.widget.Toolbar$1.onMenuItemClick(Toolbar.java:204)
at android.support.v7.widget.ActionMenuView$MenuBuilderCallback.onMenuItemSelected(ActionMenuView.java:781)
at android.support.v7.view.menu.MenuBuilder.dispatchMenuItemSelected(MenuBuilder.java:840)
at android.support.v7.view.menu.MenuItemImpl.invoke(MenuItemImpl.java:158)
at android.support.v7.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:991)
at android.support.v7.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:981)
at android.support.v7.widget.ActionMenuView.invokeItem(ActionMenuView.java:625)
at android.support.v7.view.menu.ActionMenuItemView.onClick(ActionMenuItemView.java:151)
at android.view.View.performClick(View.java:6297)
at android.view.View$PerformClick.run(View.java:24797)
at android.os.Handler.handleCallback(Handler.java:790)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:6626)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:811)
Would you like to work on the issue?
Yes