From c2f6dd6b0aab6c35424ea6a47974c99bc60b9fc3 Mon Sep 17 00:00:00 2001 From: olly Date: Mon, 21 Jan 2019 12:44:07 +0000 Subject: [PATCH] Only allow one layer of sub-directories in the cache for now PiperOrigin-RevId: 230209898 --- .../google/android/exoplayer2/upstream/cache/SimpleCache.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/core/src/main/java/com/google/android/exoplayer2/upstream/cache/SimpleCache.java b/library/core/src/main/java/com/google/android/exoplayer2/upstream/cache/SimpleCache.java index 80eb779e39..7f9bdde5c1 100644 --- a/library/core/src/main/java/com/google/android/exoplayer2/upstream/cache/SimpleCache.java +++ b/library/core/src/main/java/com/google/android/exoplayer2/upstream/cache/SimpleCache.java @@ -405,7 +405,7 @@ public final class SimpleCache implements Cache { } for (File file : files) { String fileName = file.getName(); - if (fileName.indexOf('.') == -1) { + if (isRootDirectory && fileName.indexOf('.') == -1) { loadDirectory(file, /* isRootDirectory= */ false); } else { if (isRootDirectory && CachedContentIndex.FILE_NAME.equals(fileName)) {