summaryrefslogtreecommitdiffstats
path: root/src/com/android/gallery3d/app/SlideshowPage.java
diff options
context:
space:
mode:
authorRay Chen <raychen@google.com>2011-11-03 15:47:38 +0800
committerRay Chen <raychen@google.com>2011-11-03 15:47:38 +0800
commit506200619672fa8221b98d50efbe77c777fae3e9 (patch)
treef6ba42fd967ec6ea8a77440f3c8f9df818804665 /src/com/android/gallery3d/app/SlideshowPage.java
parenta98d3c4dbed84296496f5f710bd1289d735581d5 (diff)
downloadandroid_packages_apps_Gallery2-506200619672fa8221b98d50efbe77c777fae3e9.tar.gz
android_packages_apps_Gallery2-506200619672fa8221b98d50efbe77c777fae3e9.tar.bz2
android_packages_apps_Gallery2-506200619672fa8221b98d50efbe77c777fae3e9.zip
Fix 5556160 Crash in gallery after playing slideshow Crespo IML33B.
Change-Id: Ia3de43eae5d96c9f1674dd1ccb01dc004612bda9
Diffstat (limited to 'src/com/android/gallery3d/app/SlideshowPage.java')
-rw-r--r--src/com/android/gallery3d/app/SlideshowPage.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/com/android/gallery3d/app/SlideshowPage.java b/src/com/android/gallery3d/app/SlideshowPage.java
index 629bfd796..938785e9e 100644
--- a/src/com/android/gallery3d/app/SlideshowPage.java
+++ b/src/com/android/gallery3d/app/SlideshowPage.java
@@ -203,7 +203,8 @@ public class SlideshowPage extends ActivityState {
setStateResult(Activity.RESULT_OK, mResultIntent.putExtra(KEY_PHOTO_INDEX, 0));
} else {
int index = data.getInt(KEY_PHOTO_INDEX);
- Path path = Path.fromString(data.getString(KEY_ITEM_PATH));
+ String itemPath = data.getString(KEY_ITEM_PATH);
+ Path path = itemPath != null ? Path.fromString(itemPath) : null;
boolean repeat = data.getBoolean(KEY_REPEAT);
mModel = new SlideshowDataAdapter(mActivity, new SequentialSource(mediaSet, repeat),
index, path);