axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sam...@apache.org
Subject svn commit: r453067 - in /webservices/axis2/trunk/c/modules/core: clientapi/svc_client.c context/msg_ctx.c transport/http/http_transport_utils.c transport/http/sender/http_transport_sender.c transport/http/sender/soap_over_http_sender.c
Date Wed, 04 Oct 2006 23:44:10 GMT
Author: samisa
Date: Wed Oct  4 16:44:09 2006
New Revision: 453067

URL: http://svn.apache.org/viewvc?view=rev&rev=453067
Log:
Fixed the action problem in SOAP 1.1 content header and also sending MIME headers when not
needed

Modified:
    webservices/axis2/trunk/c/modules/core/clientapi/svc_client.c
    webservices/axis2/trunk/c/modules/core/context/msg_ctx.c
    webservices/axis2/trunk/c/modules/core/transport/http/http_transport_utils.c
    webservices/axis2/trunk/c/modules/core/transport/http/sender/http_transport_sender.c
    webservices/axis2/trunk/c/modules/core/transport/http/sender/soap_over_http_sender.c

Modified: webservices/axis2/trunk/c/modules/core/clientapi/svc_client.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/clientapi/svc_client.c?view=diff&rev=453067&r1=453066&r2=453067
==============================================================================
--- webservices/axis2/trunk/c/modules/core/clientapi/svc_client.c (original)
+++ webservices/axis2/trunk/c/modules/core/clientapi/svc_client.c Wed Oct  4 16:44:09 2006
@@ -893,10 +893,10 @@
         AXIS2_OP_CLIENT_EXECUTE(op_client, env, AXIS2_TRUE);
         res_msg_ctx = (axis2_msg_ctx_t *)AXIS2_OP_CLIENT_GET_MSG_CTX(op_client, env, AXIS2_WSDL_MESSAGE_LABEL_IN_VALUE);
 
-	if (res_msg_ctx)
-	  soap_envelope = AXIS2_MSG_CTX_GET_SOAP_ENVELOPE(res_msg_ctx, env);
-	else
-	  return NULL;
+        if (res_msg_ctx)
+          soap_envelope = AXIS2_MSG_CTX_GET_SOAP_ENVELOPE(res_msg_ctx, env);
+        else
+          return NULL;
     }
 
     if (qname_free_flag)

Modified: webservices/axis2/trunk/c/modules/core/context/msg_ctx.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/context/msg_ctx.c?view=diff&rev=453067&r1=453066&r2=453067
==============================================================================
--- webservices/axis2/trunk/c/modules/core/context/msg_ctx.c (original)
+++ webservices/axis2/trunk/c/modules/core/context/msg_ctx.c Wed Oct  4 16:44:09 2006
@@ -2440,8 +2440,6 @@
             AXIS2_OPTIONS_GET_PROPERTIES(options, env));
     rest_val = (axis2_char_t *)AXIS2_MSG_CTX_GET_PROPERTY(msg_ctx, env,
             AXIS2_ENABLE_REST, AXIS2_FALSE);
-    axis2_msg_ctx_set_soap_action(msg_ctx, env,
-            AXIS2_OPTIONS_GET_ACTION(options, env));
     if (rest_val)
     {
         if (AXIS2_STRCMP(rest_val, AXIS2_VALUE_TRUE) == 0)

Modified: webservices/axis2/trunk/c/modules/core/transport/http/http_transport_utils.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/transport/http/http_transport_utils.c?view=diff&rev=453067&r1=453066&r2=453067
==============================================================================
--- 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 Wed Oct 
4 16:44:09 2006
@@ -302,11 +302,6 @@
         AXIS2_FREE(env->allocator, mime_boundary);
     }
 
-
-    /*TODO for MTOM:create a basic stream
-    set callback_ctx.in_stream to this basic stream
-    make callback_ctx.chunked_stream null but keep the referance */
-
     AXIS2_MSG_CTX_SET_WSA_ACTION(msg_ctx, env, soap_action_header);
     AXIS2_MSG_CTX_SET_SOAP_ACTION(msg_ctx, env, soap_action_header);
     AXIS2_MSG_CTX_SET_TO(msg_ctx, env, axis2_endpoint_ref_create(env,
@@ -1257,7 +1252,14 @@
         return NULL;
     }
     tmp2 =  AXIS2_STRDUP(tmp + 1, env);
+    
     AXIS2_FREE(env->allocator, tmp_content_type);
+    if (*tmp2 == '"')
+    {
+        tmp = tmp2;
+        tmp2 =  AXIS2_STRDUP(tmp + 1, env);
+        tmp2[strlen(tmp2) - 1] = '\0';
+    }
     return tmp2;
 }
 

Modified: webservices/axis2/trunk/c/modules/core/transport/http/sender/http_transport_sender.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/transport/http/sender/http_transport_sender.c?view=diff&rev=453067&r1=453066&r2=453067
==============================================================================
--- webservices/axis2/trunk/c/modules/core/transport/http/sender/http_transport_sender.c (original)
+++ webservices/axis2/trunk/c/modules/core/transport/http/sender/http_transport_sender.c Wed
Oct  4 16:44:09 2006
@@ -581,10 +581,10 @@
 
     url = AXIS2_ENDPOINT_REF_GET_ADDRESS(epr, env);
     soap_action = AXIS2_MSG_CTX_GET_SOAP_ACTION(msg_ctx, env);
-    if (NULL == soap_action || 0 == AXIS2_STRLEN(soap_action))
+    /*hack if (NULL == soap_action || 0 == AXIS2_STRLEN(soap_action))
     {
         soap_action = AXIS2_MSG_CTX_GET_WSA_ACTION(msg_ctx, env);
-    }
+    }*/
     if (NULL == soap_action)
     {
         soap_action = "";

Modified: webservices/axis2/trunk/c/modules/core/transport/http/sender/soap_over_http_sender.c
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/c/modules/core/transport/http/sender/soap_over_http_sender.c?view=diff&rev=453067&r1=453066&r2=453067
==============================================================================
--- webservices/axis2/trunk/c/modules/core/transport/http/sender/soap_over_http_sender.c (original)
+++ webservices/axis2/trunk/c/modules/core/transport/http/sender/soap_over_http_sender.c Wed
Oct  4 16:44:09 2006
@@ -271,7 +271,7 @@
     }
 
     AXIOM_OUTPUT_SET_DO_OPTIMIZE(sender_impl->om_output, env,
-            doing_mtom);
+            doing_mtom); 
 
     AXIOM_SOAP_ENVELOPE_SERIALIZE(out, env, sender_impl->om_output,
             AXIS2_FALSE);
@@ -364,10 +364,14 @@
         content_type = (axis2_char_t *)AXIS2_HTTP_HEADER_ACCEPT_APPL_SOAP;
         content_type = AXIS2_STRACAT(content_type, ";charset=", env);
         content_type = AXIS2_STRACAT(content_type, char_set_enc, env);
-        content_type = AXIS2_STRACAT(content_type, ";action=", env);
-        content_type = AXIS2_STRACAT(content_type, soap_action, env);
+        if (axis2_strcmp(soap_action, ""))
+        {
+            content_type = AXIS2_STRACAT(content_type, ";action=", env);
+            content_type = AXIS2_STRACAT(content_type, soap_action, env);
+        }
         content_type = AXIS2_STRACAT(content_type, ";", env);
     }
+
     http_header = axis2_http_header_create(env, AXIS2_HTTP_HEADER_CONTENT_TYPE,
             content_type);
     if (content_type)



---------------------------------------------------------------------
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