You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by gd...@apache.org on 2009/08/03 05:05:08 UTC
svn commit: r800187 -
/webservices/axis2/branches/java/1_5/modules/kernel/src/org/apache/axis2/context/MessageContext.java
Author: gdaniels
Date: Mon Aug 3 03:05:08 2009
New Revision: 800187
URL: http://svn.apache.org/viewvc?rev=800187&view=rev
Log:
Protect against NPE by applying patch in https://issues.apache.org/jira/browse/AXIS2-4114.
Modified:
webservices/axis2/branches/java/1_5/modules/kernel/src/org/apache/axis2/context/MessageContext.java
Modified: webservices/axis2/branches/java/1_5/modules/kernel/src/org/apache/axis2/context/MessageContext.java
URL: http://svn.apache.org/viewvc/webservices/axis2/branches/java/1_5/modules/kernel/src/org/apache/axis2/context/MessageContext.java?rev=800187&r1=800186&r2=800187&view=diff
==============================================================================
--- webservices/axis2/branches/java/1_5/modules/kernel/src/org/apache/axis2/context/MessageContext.java (original)
+++ webservices/axis2/branches/java/1_5/modules/kernel/src/org/apache/axis2/context/MessageContext.java Mon Aug 3 03:05:08 2009
@@ -1606,8 +1606,17 @@
return null;
}
- String direction = axisMessage.getDirection();
- AxisBindingMessage axisBindingMessage = null;
+ String direction;
+ if (axisMessage != null) {
+ direction = axisMessage.getDirection();
+ } else {
+ if ((FLOW == IN_FLOW) || (FLOW == IN_FAULT_FLOW)) {
+ direction = WSDLConstants.WSDL_MESSAGE_DIRECTION_IN;
+ } else {
+ direction = WSDLConstants.WSDL_MESSAGE_DIRECTION_OUT;
+ }
+ }
+ AxisBindingMessage axisBindingMessage;
if (WSDLConstants.WSDL_MESSAGE_DIRECTION_IN
.equals(direction)
&& WSDLUtil
@@ -2204,7 +2213,7 @@
* able to find matching objects when the message
* context is re-constituted.
*
- * @param out The stream to write the object contents to
+ * @param o The stream to write the object contents to
* @throws IOException
*/
public void writeExternal(ObjectOutput o) throws IOException {
@@ -2790,7 +2799,7 @@
* as it was written. Some data will need to be validated when
* resurrected.
*
- * @param in The stream to read the object contents from
+ * @param inObject
* @throws IOException
* @throws ClassNotFoundException
*/