This commit is contained in:
Phillip Webb
2016-04-12 13:21:31 -07:00
parent 0968d411e6
commit 5bc274ca09
2 changed files with 4 additions and 0 deletions

View File

@@ -259,6 +259,7 @@ public class JarFile extends java.util.jar.JarFile {
private JarFile createJarFileFromDirectoryEntry(JarEntry entry) throws IOException {
final AsciiBytes sourceName = new AsciiBytes(entry.getName());
JarEntryFilter filter = new JarEntryFilter() {
@Override
public AsciiBytes apply(AsciiBytes name) {
if (name.startsWith(sourceName) && !name.equals(sourceName)) {
@@ -266,6 +267,7 @@ public class JarFile extends java.util.jar.JarFile {
}
return null;
}
};
return new JarFile(this.rootFile,
this.pathFromRoot + "!/"