[Android] Fix crash in equalizer

Nicolas Pomepuy git at videolan.org
Fri Apr 26 12:45:37 CEST 2019


vlc-android | branch: master | Nicolas Pomepuy <nicolas.pomepuy at gmail.com> | Wed Apr 17 11:18:00 2019 +0200| [8430b761c6ee764db962154caa475f635de8271c] | committer: Geoffrey Métais

Fix crash in equalizer

> https://code.videolan.org/videolan/vlc-android/commit/8430b761c6ee764db962154caa475f635de8271c
---

 vlc-android/src/org/videolan/vlc/gui/audio/EqualizerFragment.kt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/vlc-android/src/org/videolan/vlc/gui/audio/EqualizerFragment.kt b/vlc-android/src/org/videolan/vlc/gui/audio/EqualizerFragment.kt
index 3e64bd880..876ffc631 100644
--- a/vlc-android/src/org/videolan/vlc/gui/audio/EqualizerFragment.kt
+++ b/vlc-android/src/org/videolan/vlc/gui/audio/EqualizerFragment.kt
@@ -419,7 +419,7 @@ class EqualizerFragment : AppCompatDialogFragment() {
                 if (count <= 0) return null
                 val presets = ArrayList<String>(count)
                 for (i in 0 until count) {
-                    presets[i] = MediaPlayer.Equalizer.getPresetName(i)
+                    presets.add(MediaPlayer.Equalizer.getPresetName(i))
                 }
                 return presets.toTypedArray()
             }



More information about the Android mailing list