Fix an issue when there's a dir with the same base name as a class path entry

This commit is contained in:
Ben Gruver 2013-04-09 17:40:53 -07:00
parent 7e58d497ef
commit 5c6cad2822

View File

@ -178,7 +178,7 @@ public class ClassPath {
for (String ext: new String[]{"", ".odex", ".jar", ".apk", ".zip"}) {
File file = new File(classPathDir, baseEntryName + ext);
if (file.exists()) {
if (file.exists() && file.isFile()) {
if (!file.canRead()) {
System.err.println(String.format(
"warning: cannot open %s for reading. Will continue looking.", file.getPath()));