mirror of
https://github.com/ysoftdevs/DependencyCheck.git
synced 2026-03-26 19:11:29 +01:00
updated exception handling
This commit is contained in:
@@ -86,6 +86,14 @@ public class AggregateMojo extends BaseDependencyCheckMojo {
|
|||||||
exCol.getExceptions().addAll(ex.getExceptions());
|
exCol.getExceptions().addAll(ex.getExceptions());
|
||||||
if (ex.isFatal()) {
|
if (ex.isFatal()) {
|
||||||
exCol.setFatal(true);
|
exCol.setFatal(true);
|
||||||
|
final String msg = String.format("Fatal exception(s) analyzing %s", childProject.getName());
|
||||||
|
if (this.isFailOnError()) {
|
||||||
|
throw new MojoExecutionException(msg, exCol);
|
||||||
|
}
|
||||||
|
getLog().error(msg);
|
||||||
|
if (getLog().isDebugEnabled()) {
|
||||||
|
getLog().debug(exCol);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user