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)) {