mirror of
https://github.com/apache/maven.git
synced 2025-02-23 02:15:50 +00:00
directories don't always come first - make them if they don't exist
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@164394 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
657fde08f4
commit
09764d0531
@ -222,14 +222,11 @@ private void unpackJar( File file, File tempLocation )
|
||||
{
|
||||
JarEntry entry = (JarEntry) e.nextElement();
|
||||
|
||||
if ( entry.isDirectory() )
|
||||
if ( !entry.isDirectory() )
|
||||
{
|
||||
new File( tempLocation, entry.getName() ).mkdir();
|
||||
}
|
||||
else
|
||||
{
|
||||
IOUtil.copy( jar.getInputStream( entry ),
|
||||
new FileOutputStream( new File( tempLocation, entry.getName() ) ) );
|
||||
File outFile = new File( tempLocation, entry.getName() );
|
||||
outFile.getParentFile().mkdirs();
|
||||
IOUtil.copy( jar.getInputStream( entry ), new FileOutputStream( outFile ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user