[MNG-4464] Improve handling of relative paths with backslashes

git-svn-id: https://svn.apache.org/repos/asf/maven/maven-3/trunk@904931 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Benjamin Bentmann 2010-01-31 00:27:21 +00:00
parent d0d3f58fff
commit 8b6616cf3b
4 changed files with 7 additions and 1 deletions

View File

@ -338,6 +338,8 @@ private boolean build( List<ProjectBuildingResult> results, List<InterimResult>
continue;
}
module = module.replace( '\\', File.separatorChar ).replace( '/', File.separatorChar );
File moduleFile = new File( basedir, module );
if ( moduleFile.isDirectory() )

View File

@ -545,6 +545,8 @@ private File getParentPomFile( Model childModel )
String parentPath = childModel.getParent().getRelativePath();
parentPath = parentPath.replace( '\\', File.separatorChar ).replace( '/', File.separatorChar );
File pomFile = new File( new File( projectDirectory, parentPath ).toURI().normalize() );
if ( pomFile.isDirectory() )

View File

@ -39,6 +39,8 @@ public String alignToBaseDirectory( String path, File basedir )
if ( path != null && basedir != null )
{
path = path.replace( '\\', File.separatorChar ).replace( '/', File.separatorChar );
File file = new File( path );
if ( file.isAbsolute() )
{

View File

@ -41,7 +41,7 @@
<commonsCliVersion>1.2</commonsCliVersion>
<easyMockVersion>1.2_Java1.3</easyMockVersion>
<junitVersion>3.8.2</junitVersion>
<plexusVersion>1.5.3</plexusVersion>
<plexusVersion>1.5.4</plexusVersion>
<plexusInterpolationVersion>1.11</plexusInterpolationVersion>
<plexusPluginManagerVersion>1.0-alpha-1</plexusPluginManagerVersion>
<plexusUtilsVersion>2.0.1</plexusUtilsVersion>