diff options
author | Tom Tromey <tromey@redhat.com> | 2006-05-17 22:48:02 +0000 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 2006-05-17 22:48:02 +0000 |
commit | a16aefb5a523fe18b6c60121cc367822a22e6b24 (patch) | |
tree | db1c8f8dbda26b8c29649485bd9ce40261b3c231 /tools | |
parent | 4a947e6c9d857df0a70f87a1dee50d5d00d9a786 (diff) | |
download | classpath-a16aefb5a523fe18b6c60121cc367822a22e6b24.tar.gz |
* tools/gnu/classpath/tools/jar/Indexer.java (indexJarFile): Use a
LinkedHashSet.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/gnu/classpath/tools/jar/Indexer.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/gnu/classpath/tools/jar/Indexer.java b/tools/gnu/classpath/tools/jar/Indexer.java index 86fe4ee36..aae25f821 100644 --- a/tools/gnu/classpath/tools/jar/Indexer.java +++ b/tools/gnu/classpath/tools/jar/Indexer.java @@ -46,8 +46,8 @@ import java.io.IOException; import java.io.OutputStream; import java.text.MessageFormat; import java.util.Enumeration; -import java.util.HashSet; import java.util.Iterator; +import java.util.LinkedHashSet; import java.util.StringTokenizer; import java.util.jar.Attributes; import java.util.jar.JarEntry; @@ -70,7 +70,9 @@ public class Indexer JarFile jf = new JarFile(fileName); // Index the files in this jar. - HashSet entries = new HashSet(); + // The results look a little better if we keep them + // in insertion order. + LinkedHashSet entries = new LinkedHashSet(); Enumeration e = jf.entries(); while (e.hasMoreElements()) { |