You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by se...@apache.org on 2008/02/20 22:23:27 UTC

svn commit: r629617 - in /webservices/axis2/trunk/c/src/core/transport/http/server: IIS/axis2_iis_worker.c apache2/apache2_worker.c

Author: senaka
Date: Wed Feb 20 13:23:22 2008
New Revision: 629617

URL: http://svn.apache.org/viewvc?rev=629617&view=rev
Log:
Fixing JIRA Issue AXIS2C-990

Modified:
    webservices/axis2/trunk/c/src/core/transport/http/server/IIS/axis2_iis_worker.c
    webservices/axis2/trunk/c/src/core/transport/http/server/apache2/apache2_worker.c

Modified: webservices/axis2/trunk/c/src/core/transport/http/server/IIS/axis2_iis_worker.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/src/core/transport/http/server/IIS/axis2_iis_worker.c?rev=629617&r1=629616&r2=629617&view=diff
==============================================================================
--- webservices/axis2/trunk/c/src/core/transport/http/server/IIS/axis2_iis_worker.c (original)
+++ webservices/axis2/trunk/c/src/core/transport/http/server/IIS/axis2_iis_worker.c Wed Feb 20 13:23:22 2008
@@ -146,8 +146,10 @@
     CHAR server_name[MAX_SERVERNAME];
     axis2_char_t port[MAX_TCP_PORT_LEN];
     CHAR redirect_url[INTERNET_MAX_PATH_LENGTH];
-    soap_action[0] = '\0';
+    axis2_op_ctx_t *op_ctx = NULL;
 
+    soap_action[0] = '\0';
+    
     /*Check the parameters*/
     if (!lpECB)
     {
@@ -309,9 +311,9 @@
         }
     }
     /* Nothing wrong has happen. So proceed with the request*/
+    op_ctx = axis2_msg_ctx_get_op_ctx(msg_ctx, env);
     if (-1 == send_status)
     {
-        axis2_op_ctx_t * op_ctx = axis2_msg_ctx_get_op_ctx(msg_ctx, env);
         if (axis2_op_ctx_get_response_written(op_ctx, env))
         {
             if (out_stream)
@@ -363,6 +365,49 @@
                 " writing response.");
         }
     }
+    if (op_ctx)
+    {
+        axis2_msg_ctx_t *out_msg_ctx = NULL,
+            *in_msg_ctx = NULL;
+        axis2_msg_ctx_t **msg_ctx_map = NULL;
+        axis2_char_t *msg_id = NULL;
+        axis2_conf_ctx_t *conf_ctx = NULL;
+        msg_ctx_map = axis2_op_ctx_get_msg_ctx_map(op_ctx, env);
+
+        out_msg_ctx = msg_ctx_map[AXIS2_WSDL_MESSAGE_LABEL_OUT];
+        in_msg_ctx = msg_ctx_map[AXIS2_WSDL_MESSAGE_LABEL_IN];
+
+        if (out_msg_ctx)
+        {
+            axis2_msg_ctx_free(out_msg_ctx, env);
+            out_msg_ctx = NULL;
+            msg_ctx_map[AXIS2_WSDL_MESSAGE_LABEL_OUT] = NULL;
+        }
+
+        if (in_msg_ctx)
+        {
+            msg_id =
+                axutil_strdup(env, axis2_msg_ctx_get_msg_id(in_msg_ctx, env));
+            conf_ctx = axis2_msg_ctx_get_conf_ctx(in_msg_ctx, env);
+            axis2_msg_ctx_reset_http_out_transport_info(in_msg_ctx, env);
+            axis2_msg_ctx_reset_transport_out_stream(in_msg_ctx, env);
+            axis2_msg_ctx_free(in_msg_ctx, env);
+            in_msg_ctx = NULL;
+            msg_ctx_map[AXIS2_WSDL_MESSAGE_LABEL_IN] = NULL;
+        }
+
+        if (!axis2_op_ctx_is_in_use(op_ctx, env))
+        {
+            axis2_op_ctx_destroy_mutex(op_ctx, env);
+            if (conf_ctx && msg_id)
+            {
+                axis2_conf_ctx_register_op_ctx(conf_ctx, env, msg_id, NULL);
+                AXIS2_FREE(env->allocator, msg_id);
+            }
+            axis2_op_ctx_free(op_ctx, env);
+        }
+
+    }                           /* Done freeing message contexts */
     if (request_body)
     {
         axutil_stream_free(request_body, env);

Modified: webservices/axis2/trunk/c/src/core/transport/http/server/apache2/apache2_worker.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/src/core/transport/http/server/apache2/apache2_worker.c?rev=629617&r1=629616&r2=629617&view=diff
==============================================================================
--- webservices/axis2/trunk/c/src/core/transport/http/server/apache2/apache2_worker.c (original)
+++ webservices/axis2/trunk/c/src/core/transport/http/server/apache2/apache2_worker.c Wed Feb 20 13:23:22 2008
@@ -425,7 +425,7 @@
             msg_id =
                 axutil_strdup(env, axis2_msg_ctx_get_msg_id(in_msg_ctx, env));
             conf_ctx = axis2_msg_ctx_get_conf_ctx(in_msg_ctx, env);
-
+            axis2_msg_ctx_reset_http_out_transport_info(in_msg_ctx, env);
             axis2_msg_ctx_free(in_msg_ctx, env);
             in_msg_ctx = NULL;
             msg_ctx_map[AXIS2_WSDL_MESSAGE_LABEL_IN] = NULL;



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