axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject svn commit: r642592 - /webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/MessageContextBuilder.java
Date Sat, 29 Mar 2008 19:43:35 GMT
Author: dims
Date: Sat Mar 29 12:43:34 2008
New Revision: 642592

URL: http://svn.apache.org/viewvc?rev=642592&view=rev
Log:
Fix for AXIS2-3602 - NPE in MessageContextBuilder.createFaultEnvelope and SOAP12Constants.SOAP_FAULT_NODE_LOCAL_NAME
property set in message context (prevent NPE)

Modified:
    webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/MessageContextBuilder.java

Modified: webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/MessageContextBuilder.java
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/MessageContextBuilder.java?rev=642592&r1=642591&r2=642592&view=diff
==============================================================================
--- webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/MessageContextBuilder.java
(original)
+++ webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/util/MessageContextBuilder.java
Sat Mar 29 12:43:34 2008
@@ -37,6 +37,7 @@
 import org.apache.axiom.soap.SOAPHeader;
 import org.apache.axiom.soap.SOAPHeaderBlock;
 import org.apache.axiom.soap.SOAPProcessingException;
+import org.apache.axiom.soap.SOAPFaultNode;
 import org.apache.axis2.AxisFault;
 import org.apache.axis2.Constants;
 import org.apache.axis2.addressing.AddressingConstants;
@@ -569,7 +570,10 @@
 
         Object faultNode = context.getProperty(SOAP12Constants.SOAP_FAULT_NODE_LOCAL_NAME);
         if (faultNode != null) {
-            fault.getNode().setText((String) faultNode);
+            SOAPFaultNode soapFaultNode = fault.getNode();
+            if(soapFaultNode != null) {
+                soapFaultNode.setText((String) faultNode);
+            }
         } else if (axisFault != null) {
             if (axisFault.getFaultNodeElement() != null) {
                 fault.setNode(axisFault.getFaultNodeElement());



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Mime
View raw message