axis-c-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sanjiva Weerawarana" <sanj...@opensource.lk>
Subject Fw: Three work arounds OR Bug
Date Fri, 19 Mar 2004 09:59:17 GMT

----- Original Message -----
From: <shivk@accelrys.com>
To: "Apache AXIS C User List" <axis-c-user@ws.apache.org>
Sent: Friday, March 19, 2004 11:17 AM
Subject: Three work arounds OR Bug


> Hi,
> I wrote a webservice client using Axis CPP. Everything worked fine but I
> faced problem in getting string of 3k+ from web service. Please note that
> two more user had complained about this.
> I did not get any answer from this group so i investigated myself and
> found work arounds (These could be bug in Axis CPP but only concerned
> developer can confirm this).
>
> 1.
> Problem : When return string is more than 4K then sockets does not receive
> that properly.
> File name: Channel.cpp
> Method : const Channel& Channel::operator >> (std::string& msg)
> Old line : buf[nByteRecv+1] = '\0';
> Changed : buf[nByteRecv] = '\0';
> Explanation: Socket receives "nByteRecv" bytes in char array from 0 to
> nByteRecv-1 ,So buf[nByteRecv] = '\0'; should be done.
>
> 2.
> Problem : When return string is more than 1K then last byte is truncated.
> File name: XMLStreamHandler.cpp
> Method :  void  XMLStreamHandler::characters (const XMLCh *const
> chars,const unsigned int length)
> Old line :  AxisChar* pchar = new AxisChar[nLen];
>           if (XMLString::transcode( chars, pchar, nLen-1))
> Changed : AxisChar* pchar = new AxisChar[nLen + 1];
>              if (XMLString::transcode( chars, pchar, nLen))
> Explanation: This is very common bug we face so I feel we do not need
> explanation.
>
> 3.
> Problem : Character array is added to integer. Sometime it throws
> exception.
> File name: Receiver.cpp
> Method :  const char* Receiver::Recv(int nMaxToRead) throw (AxisException)
> Old line :  m_pMsg += m_BytesRead;
> Changed : comment this line.
> Explanation:
>
>
>
> Thanks & Regards
> Shiv Kumar
>


Mime
View raw message