You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2014/05/21 23:59:37 UTC
[2/3] git commit: [CXF-5759] Make the cxf-cjx-plugin fail on parsing
errors
[CXF-5759] Make the cxf-cjx-plugin fail on parsing errors
Project: http://git-wip-us.apache.org/repos/asf/cxf-xjc-utils/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf-xjc-utils/commit/62d190d7
Tree: http://git-wip-us.apache.org/repos/asf/cxf-xjc-utils/tree/62d190d7
Diff: http://git-wip-us.apache.org/repos/asf/cxf-xjc-utils/diff/62d190d7
Branch: refs/heads/master
Commit: 62d190d7e0f6fa087fc69810f4d49910c685297f
Parents: 3a30a39
Author: Daniel Kulp <dk...@apache.org>
Authored: Wed May 21 16:19:11 2014 -0400
Committer: Daniel Kulp <dk...@apache.org>
Committed: Wed May 21 16:19:11 2014 -0400
----------------------------------------------------------------------
.../java/org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cxf-xjc-utils/blob/62d190d7/cxf-xjc-plugin/src/main/java/org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java
----------------------------------------------------------------------
diff --git a/cxf-xjc-plugin/src/main/java/org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java b/cxf-xjc-plugin/src/main/java/org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java
index 8d86371..a4938ce 100644
--- a/cxf-xjc-plugin/src/main/java/org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java
+++ b/cxf-xjc-plugin/src/main/java/org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java
@@ -154,7 +154,10 @@ public abstract class AbstractXSDToJavaMojo extends AbstractMojo {
buildContext.addMessage(file, exception.getLineNumber(), exception.getColumnNumber(),
mapMessage(exception.getLocalizedMessage()),
BuildContext.SEVERITY_ERROR, exception);
-
+ if (firstError == null) {
+ firstError = exception;
+ firstError.fillInStackTrace();
+ }
}
private String mapMessage(String localizedMessage) {