axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ros...@apache.org
Subject cvs commit: ws-axis/c/src/transport/axis HttpTransport.cpp
Date Tue, 06 Jul 2004 13:09:40 GMT
roshan      2004/07/06 06:09:40

  Modified:    c/src/transport/axis HttpTransport.cpp
  Log:
  Made changes to remove duplicate SOAPActions if any
  
  Revision  Changes    Path
  1.39      +29 -2     ws-axis/c/src/transport/axis/HttpTransport.cpp
  
  Index: HttpTransport.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/transport/axis/HttpTransport.cpp,v
  retrieving revision 1.38
  retrieving revision 1.39
  diff -u -r1.38 -r1.39
  --- HttpTransport.cpp	6 Jul 2004 08:34:42 -0000	1.38
  +++ HttpTransport.cpp	6 Jul 2004 13:09:40 -0000	1.39
  @@ -14,11 +14,12 @@
    *   limitations under the License.
    */
   
  -/*
  +/**
    * @author Lilantha Darshana (lilantha@virtusa.com)
    * @author Damitha Kumarage (damitha@jkcsworld.com, damitha@opensource.lk)
    * @author Susantha Kumara (susantha@opensource.lk, skumara@virtusa.com)
    * @author Samisa Abeysinghe (sabeysinghe@virtusa.com)
  + * @author Roshan Weerasuriya (roshan@opensource.lk, roshanw@jkcsworld.com)
    */
   
   /*
  @@ -37,6 +38,14 @@
    * Added setTimeout
    */
   
  +/*
  + * Revision 1.4  2004/07/06 roshan
  + * Added code to "SetProperty (const char *p_Property, const char *p_Value)"
  + *  method. The purpose of this change is not to allow duplicating SOAPAction
  + *  HTTP Header.
  + */
  +
  +
   #ifdef WIN32
   #pragma warning (disable : 4101)
   #endif
  @@ -168,7 +177,25 @@
   void
   HttpTransport::SetProperty (const char *p_Property, const char *p_Value)
   {
  -    m_AdditionalHeader.push_back (std::make_pair ((string)p_Property,(string) p_Value));
  +    bool b_SOAPActionFound = false;
  +
  +    if (strcmp(p_Property, "SOAPAction") == 0)
  +    {
  +    for (unsigned int i = 0; i < m_AdditionalHeader.size (); i++)
  +    {
  +        if (m_AdditionalHeader[i].first == "SOAPAction")
  +        {
  +            m_AdditionalHeader[i].second = (string)p_Value;
  +	    b_SOAPActionFound = true;
  +	    break;
  +        }
  +    }
  +    }
  +
  +    if (b_SOAPActionFound == false)
  +    {
  +	 m_AdditionalHeader.push_back (std::make_pair ((string)p_Property,(string) p_Value));
  +    }
   }
   
   
  
  
  

Mime
View raw message