Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-17565] Android-L: KS Phone-> Gallery crashes when backing out of test

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2014-08-29T20:57:01.000+0000
Affected Version/sRelease 3.3.0
Fix Version/sRelease 3.4.0
ComponentsAndroid
Labelsandroid-l, module_kitchensink, qe-manualtest
ReporterHieu Pham
AssigneeHieu Pham
Created2014-08-26T23:55:40.000+0000
Updated2014-08-29T20:57:01.000+0000

Description

In KitchenSink, go to Phone -> Photo Gallery. Hit the back button, observe crash
08-26 16:54:37.232: E/AndroidRuntime(2664): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.startsWith(java.lang.String)' on a null object reference
08-26 16:54:37.232: E/AndroidRuntime(2664): 	at org.appcelerator.titanium.io.TiFileFactory.createTitaniumFile(TiFileFactory.java:56)
08-26 16:54:37.232: E/AndroidRuntime(2664): 	at ti.modules.titanium.media.MediaModule.createDictForImage(MediaModule.java:823)
08-26 16:54:37.232: E/AndroidRuntime(2664): 	at ti.modules.titanium.media.MediaModule$1.onResult(MediaModule.java:794)
08-26 16:54:37.232: E/AndroidRuntime(2664): 	at org.appcelerator.titanium.util.TiActivitySupportHelper$1.onResult(TiActivitySupportHelper.java:58)
08-26 16:54:37.232: E/AndroidRuntime(2664): 	at org.appcelerator.titanium.util.TiActivitySupportHelper.onActivityResult(TiActivitySupportHelper.java:107)
08-26 16:54:37.232: E/AndroidRuntime(2664): 	at org.appcelerator.titanium.TiBaseActivity.onActivityResult(TiBaseActivity.java:632)
08-26 16:54:37.232: E/AndroidRuntime(2664): 	at android.app.Activity.dispatchActivityResult(Activity.java:5922)
08-26 16:54:37.232: E/AndroidRuntime(2664): 	at android.app.ActivityThread.deliverResults(ActivityThread.java:3422)
08-26 16:54:37.232: E/AndroidRuntime(2664): 	... 10 more

Test should not crash

Comments

  1. Hieu Pham 2014-08-27

    PR: https://github.com/appcelerator/titanium_mobile/pull/5990
  2. Lokesh Choudhary 2014-08-28

    Verified the fix. KS does not crash on android L when back button is hit in photogallery. Closing. Environment: Appc Studio : 3.4.0.201408270900 Ti SDK : 3.4.0.v20140827165712 Mac OSX : 10.9.4 Alloy : 1.5.0-dev CLI - 3.4.0-dev Code Processor: 1.1.1 Nexus 5 - android L preview Android L emulator
  3. Lokesh Choudhary 2014-08-29

    Reopening to add tester

JSON Source