From b6583663c85452847dcdd17d62107acfea47643c Mon Sep 17 00:00:00 2001 From: benfry Date: Sun, 10 Jun 2007 17:25:53 +0000 Subject: [PATCH] ignore . and ._ files when parsing classpath and library jar/zip files --- app/Compiler.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/app/Compiler.java b/app/Compiler.java index e975901dc..ed277abdc 100644 --- a/app/Compiler.java +++ b/app/Compiler.java @@ -406,10 +406,13 @@ public class Compiler implements MessageConsumer { if (!path.endsWith(File.separator)) { path += File.separator; } - //System.out.println("path is " + path); String list[] = folder.list(); for (int i = 0; i < list.length; i++) { + // Skip . and ._ files. Prior to 0125p3, .jar files that had + // OS X AppleDouble files associated would cause trouble. + if (list[i].startsWith(".")) continue; + if (list[i].toLowerCase().endsWith(".jar") || list[i].toLowerCase().endsWith(".zip")) { abuffer.append(sep); @@ -445,6 +448,7 @@ public class Compiler implements MessageConsumer { if (pieces[i].toLowerCase().endsWith(".jar") || pieces[i].toLowerCase().endsWith(".zip")) { + //System.out.println("checking " + pieces[i]); packageListFromZip(pieces[i], table); } else { // it's another type of file or directory