mirror of
https://github.com/apache/maven.git
synced 2025-02-23 02:15:50 +00:00
o Improved error reporting
git-svn-id: https://svn.apache.org/repos/asf/maven/maven-3/trunk@825944 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
d6ad00a1f3
commit
0514606a44
@ -310,7 +310,7 @@ private Model readModel( ModelSource modelSource, File pomFile, ModelBuildingReq
|
||||
}
|
||||
catch ( ModelParseException e )
|
||||
{
|
||||
if ( !strict || pomFile != null )
|
||||
if ( !strict )
|
||||
{
|
||||
throw e;
|
||||
}
|
||||
@ -319,7 +319,14 @@ private Model readModel( ModelSource modelSource, File pomFile, ModelBuildingReq
|
||||
|
||||
model = modelProcessor.read( modelSource.getInputStream(), options );
|
||||
|
||||
problems.addWarning( "Malformed POM " + modelSource.getLocation() + ": " + e.getMessage(), e );
|
||||
if ( pomFile != null )
|
||||
{
|
||||
problems.addError( "Malformed POM " + modelSource.getLocation() + ": " + e.getMessage(), e );
|
||||
}
|
||||
else
|
||||
{
|
||||
problems.addWarning( "Malformed POM " + modelSource.getLocation() + ": " + e.getMessage(), e );
|
||||
}
|
||||
}
|
||||
}
|
||||
catch ( ModelParseException e )
|
||||
|
Loading…
x
Reference in New Issue
Block a user