[Android] Fix potential NPE
Geoffrey Métais
git at videolan.org
Tue Jun 30 10:36:16 CEST 2015
vlc-ports/android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Tue Jun 30 09:52:16 2015 +0200| [5678d5f0f67f26806cd0dcd59681812e73f2909c] | committer: Geoffrey Métais
Fix potential NPE
> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=5678d5f0f67f26806cd0dcd59681812e73f2909c
---
vlc-android/src/org/videolan/vlc/gui/MainActivity.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vlc-android/src/org/videolan/vlc/gui/MainActivity.java b/vlc-android/src/org/videolan/vlc/gui/MainActivity.java
index 2f32903..6d5ae05 100644
--- a/vlc-android/src/org/videolan/vlc/gui/MainActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/MainActivity.java
@@ -220,7 +220,7 @@ public class MainActivity extends AudioPlayerContainerActivity implements OnItem
super.onResume();
/* FIXME: this is used to avoid having MainActivity twice in the backstack */
- if (getIntent().hasExtra(PlaybackService.START_FROM_NOTIFICATION))
+ if (getIntent() != null && getIntent().hasExtra(PlaybackService.START_FROM_NOTIFICATION))
getIntent().removeExtra(PlaybackService.START_FROM_NOTIFICATION);
More information about the Android
mailing list