[Android] Remove slashes in saved subtitle filename
Geoffrey Métais
git at videolan.org
Thu Jul 12 15:42:01 CEST 2018
vlc-android | branch: 3.0.x | Geoffrey Métais <geoffrey.metais at gmail.com> | Thu Jul 12 15:38:01 2018 +0200| [cd8631892be3f3f4b4d73eea68b76aff3ff7bbd2] | committer: Geoffrey Métais
Remove slashes in saved subtitle filename
(cherry picked from commit 65befa6c2a327b3f04e6840167f2f9c1407e2632)
> https://code.videolan.org/videolan/vlc-android/commit/cd8631892be3f3f4b4d73eea68b76aff3ff7bbd2
---
vlc-android/src/org/videolan/vlc/util/SubtitlesDownloader.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vlc-android/src/org/videolan/vlc/util/SubtitlesDownloader.java b/vlc-android/src/org/videolan/vlc/util/SubtitlesDownloader.java
index 55e69ed10..9c41f4455 100644
--- a/vlc-android/src/org/videolan/vlc/util/SubtitlesDownloader.java
+++ b/vlc-android/src/org/videolan/vlc/util/SubtitlesDownloader.java
@@ -327,7 +327,7 @@ public class SubtitlesDownloader {
if (mToken == null || path == null) return;
final StringBuilder sb = new StringBuilder();
final String name = fileName.lastIndexOf('.') > 0 ? fileName.substring(0, fileName.lastIndexOf('.')) : fileName;
- sb.append(SUBTITLES_DIRECTORY.getPath()).append('/').append(name).append('.').append(language).append('.').append(subFormat);
+ sb.append(SUBTITLES_DIRECTORY.getPath()).append('/').append(name.replace("/", "")).append('.').append(language).append('.').append(subFormat);
final String srtUrl = sb.toString();
FileOutputStream f = null;
GZIPInputStream gzIS = null;
More information about the Android
mailing list