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 sa...@apache.org on 2005/07/27 06:50:37 UTC

cvs commit: ws-axis/c/src/server/apache2 mod_axis2.cpp

samisa      2005/07/26 21:50:37

  Modified:    c/src/server/apache mod_axis.cpp
               c/src/server/apache2 mod_axis2.cpp
  Log:
  Updated code to set the content type to "text/xml" in case of GET requests with wsdl arg
  AXISCPP-519
  
  Revision  Changes    Path
  1.8       +7 -0      ws-axis/c/src/server/apache/mod_axis.cpp
  
  Index: mod_axis.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/server/apache/mod_axis.cpp,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- mod_axis.cpp	23 Nov 2004 04:00:16 -0000	1.7
  +++ mod_axis.cpp	27 Jul 2005 04:50:37 -0000	1.8
  @@ -43,6 +43,13 @@
       req_rec->content_type = (M_POST == req_rec->method_number) ? 
       "text/xml" : "text/html";
   
  +    // Samisa : if it is a GET request with wsdl arg then content type should be text/xml
  +    if (req_rec->args)
  +    {
  +        if( strcmp("wsdl", req_rec->args) == 0 )
  +            req_rec->content_type = "text/xml";
  +    }
  +
   	 /* Set up the read policy from the client.*/
       if ((rc = ap_setup_client_block(req_rec, REQUEST_CHUNKED_ERROR)) != OK)
       {
  
  
  
  1.6       +8 -0      ws-axis/c/src/server/apache2/mod_axis2.cpp
  
  Index: mod_axis2.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/server/apache2/mod_axis2.cpp,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- mod_axis2.cpp	11 Jul 2005 05:43:51 -0000	1.5
  +++ mod_axis2.cpp	27 Jul 2005 04:50:37 -0000	1.6
  @@ -46,6 +46,14 @@
        * the moment. */
       req_rec->content_type = (M_POST == req_rec->method_number) ? 
   		"text/xml" : "text/html";
  +
  +    // Samisa : if it is a GET request with wsdl arg then content type should be text/xml
  +    if (req_rec->args)
  +    {
  +        if( strcmp("wsdl", req_rec->args) == 0 )
  +            req_rec->content_type = "text/xml";
  +    }
  +
   	 /* Set up the read policy from the client.*/
       if ((rc = ap_setup_client_block(req_rec, REQUEST_CHUNKED_ERROR)) != OK)
       {