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 2015/07/08 22:42:43 UTC

[3/4] cxf-xjc-utils git commit: Merge branch 'NPE-fix' of https://github.com/spark404/cxf-xjc-utils This closes #1

Merge branch 'NPE-fix' of https://github.com/spark404/cxf-xjc-utils
This closes #1


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/ef810739
Tree: http://git-wip-us.apache.org/repos/asf/cxf-xjc-utils/tree/ef810739
Diff: http://git-wip-us.apache.org/repos/asf/cxf-xjc-utils/diff/ef810739

Branch: refs/heads/master
Commit: ef81073963ef5bf56031ad4cdb8aa42ab7f6b7ba
Parents: ad38d5a 6c7770c
Author: Daniel Kulp <dk...@apache.org>
Authored: Wed Jul 8 15:53:46 2015 -0400
Committer: Daniel Kulp <dk...@apache.org>
Committed: Wed Jul 8 15:55:40 2015 -0400

----------------------------------------------------------------------
 .../org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java     | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf-xjc-utils/blob/ef810739/cxf-xjc-plugin/src/main/java/org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java
----------------------------------------------------------------------
diff --cc cxf-xjc-plugin/src/main/java/org/apache/cxf/maven_plugin/AbstractXSDToJavaMojo.java
index 371bc22,9947e2b..5a69545
--- 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
@@@ -281,7 -281,10 +281,11 @@@ public abstract class AbstractXSDToJava
          ArtifactResolutionResult result = repository.resolve(request);
          List<File> files = new ArrayList<File>();
          for (Artifact a : result.getArtifacts()) {
+             if (a.getFile() == null) {
+                 throw new MojoExecutionException("Unable to resolve " + a.toString()
+                         + " while resolving " + artifactDescriptor);
+             }
 +            files.add(a.getFile());
          }
          if (!files.contains(artifact.getFile())) {
              files.add(artifact.getFile());