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 sa...@apache.org on 2006/01/18 01:17:04 UTC

svn commit: r369973 - in /webservices/axis2/trunk/c/modules/core: engine/engine.c transport/http/http_transport_utils.c

Author: samisa
Date: Tue Jan 17 16:16:57 2006
New Revision: 369973

URL: http://svn.apache.org/viewcvs?rev=369973&view=rev
Log:
More pointer related fixes to prevent seg faults

Modified:
    webservices/axis2/trunk/c/modules/core/engine/engine.c
    webservices/axis2/trunk/c/modules/core/transport/http/http_transport_utils.c

Modified: webservices/axis2/trunk/c/modules/core/engine/engine.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/engine/engine.c?rev=369973&r1=369972&r2=369973&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/engine/engine.c (original)
+++ webservices/axis2/trunk/c/modules/core/engine/engine.c Tue Jan 17 16:16:57 2006
@@ -343,11 +343,14 @@
 
     if (!(AXIS2_MSG_CTX_IS_PAUSED(msg_ctx, env))) 
     {
-        /* actually send the SOAP Fault*/
+        /* send the SOAP Fault*/
+        axis2_transport_sender_t *transport_sender = NULL;
         axis2_transport_out_desc_t *transport_out = AXIS2_MSG_CTX_GET_TRANSPORT_OUT_DESC(msg_ctx, env);
-        axis2_transport_sender_t *transport_sender = AXIS2_TRANSPORT_OUT_DESC_GET_SENDER(transport_out, env);
+        if (transport_out)
+            transport_sender = AXIS2_TRANSPORT_OUT_DESC_GET_SENDER(transport_out, env);
         /*TODO:Uncomment this once the implementation done*/
-        /*AXIS2_TRANSPORT_SENDER_INVOKE(transport_sender, env, msg_ctx);*/
+        if (transport_sender)
+            AXIS2_TRANSPORT_SENDER_INVOKE(transport_sender, env, msg_ctx);
     }
     return AXIS2_SUCCESS;
 }

Modified: webservices/axis2/trunk/c/modules/core/transport/http/http_transport_utils.c
URL: http://svn.apache.org/viewcvs/webservices/axis2/trunk/c/modules/core/transport/http/http_transport_utils.c?rev=369973&r1=369972&r2=369973&view=diff
==============================================================================
--- webservices/axis2/trunk/c/modules/core/transport/http/http_transport_utils.c (original)
+++ webservices/axis2/trunk/c/modules/core/transport/http/http_transport_utils.c Tue Jan 17 16:16:57 2006
@@ -208,6 +208,10 @@
 	AXIS2_MSG_CTX_SET_SOAP_ENVELOPE(msg_ctx, env, soap_envelope);
 	axis2_engine_t *engine = NULL;
 	engine = axis2_engine_create(env, conf_ctx);
+    
+    if (!soap_envelope)
+        return AXIS2_FAILURE;
+    
     axis2_soap_body_t *soap_body = AXIS2_SOAP_ENVELOPE_GET_BODY(soap_envelope, env);
     
     if (!soap_body)