diff options
author | scottkurz <scottkurz@13f79535-47bb-0310-9956-ffa450edef68> | 2009-05-14 23:01:24 +0000 |
---|---|---|
committer | scottkurz <scottkurz@13f79535-47bb-0310-9956-ffa450edef68> | 2009-05-14 23:01:24 +0000 |
commit | 0f19a869e774fe18abf71710460bf4c9f785c41b (patch) | |
tree | 630e4562db1187ab9ac0334d63cab49b5f671e67 | |
parent | 8d6ca55010b29b85c0d778345b5bb3f05fb8aa57 (diff) |
Fix NPE bug in TUSCANY-2962 fix
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@774957 13f79535-47bb-0310-9956-ffa450edef68
2 files changed, 4 insertions, 4 deletions
diff --git a/branches/sca-java-1.x/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java b/branches/sca-java-1.x/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java index b54fa6b722..46803d37fb 100644 --- a/branches/sca-java-1.x/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java +++ b/branches/sca-java-1.x/modules/binding-ws-xml/src/main/java/org/apache/tuscany/sca/binding/ws/xml/WebServiceBindingProcessor.java @@ -427,11 +427,11 @@ public class WebServiceBindingProcessor implements StAXArtifactProcessor<WebServ // Introspect the WSDL portType and validate the input/output messages. List<OperationImpl> operations = portType.getOperations(); for (OperationImpl operation : operations) { - if (operation.getInput().getMessage() == null) { + if (operation.getInput() != null && operation.getInput().getMessage() == null) { ContributionResolveException ce = new ContributionResolveException("WSDL binding operation input name " + operation.getInput().getName() + " does not match with PortType Definition"); error("ContributionResolveException", wsdlDefinition, ce); } - if (operation.getOutput().getMessage() == null) { + if (operation.getOutput() != null && operation.getOutput().getMessage() == null) { ContributionResolveException ce = new ContributionResolveException("WSDL binding operation output name " + operation.getOutput().getName() + " does not match with PortType Definition"); error("ContributionResolveException", wsdlDefinition, ce); } diff --git a/branches/sca-java-1.x/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java b/branches/sca-java-1.x/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java index 3ad2da4205..11d6a913c2 100644 --- a/branches/sca-java-1.x/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java +++ b/branches/sca-java-1.x/modules/interface-wsdl-xml/src/main/java/org/apache/tuscany/sca/interfacedef/wsdl/xml/WSDLInterfaceProcessor.java @@ -259,11 +259,11 @@ public class WSDLInterfaceProcessor implements StAXArtifactProcessor<WSDLInterfa // the input/output messages. List<OperationImpl> operations = portType.getElement().getOperations(); for (OperationImpl operation : operations) { - if (operation.getInput().getMessage() == null) { + if (operation.getInput() != null && operation.getInput().getMessage() == null) { ContributionResolveException ce = new ContributionResolveException("WSDL binding operation input name " + operation.getInput().getName() + " does not match with PortType Definition"); error("ContributionResolveException", wsdlDefinition, ce); } - if (operation.getOutput().getMessage() == null) { + if (operation.getOutput() != null && operation.getOutput().getMessage() == null) { ContributionResolveException ce = new ContributionResolveException("WSDL binding operation output name " + operation.getOutput().getName() + " does not match with PortType Definition"); error("ContributionResolveException", wsdlDefinition, ce); } |