axis-c-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Samisa Abeysinghe <samisa.abeysin...@gmail.com>
Subject Re: AXIS (1.4) crashing on when deserialising result from SOAP-Server
Date Fri, 25 Feb 2005 01:34:17 GMT
Hi,
     Could you please send the WSDL you are using and the SOAP message
sent by the server.
     Those would help regenerate the problem to help solve it.

Thanks,
Samisa...


On Thu, 24 Feb 2005 17:35:47 +0100, Nazario Cipriani
<NazarioCipriani@web.de> wrote:
> Hi everybody!
> 
> I'm having problems with AXIS1.4 + XercesC 2.2, 2.3, 2.4, 2.5, 2.6 (that are all versions
I've tested).
> 
> After invoking I get an answer from SOAP server. I do this in the way listed below (SendSOAPRequest
method from SpaSe_Client):
> 
>         if(AXIS_SUCCESS == m_pCall->checkMessage("queryResponse", endpoint))
>         {
>                 try{
>                         char* msg = m_pCall->getElementAsString("queryReturn", 0);
        // HERE THE ERROR OCCURS!!!
>                         // and so on.............
>                 }
>         }
> 
> This is a dump of the relevant elements of the call stack:
> 
>         ntdll.dll!7c901230()
>         ntdll.dll!7c96c943()
>         ntdll.dll!7c96cd80()
>         ntdll.dll!7c960af8()
>         ntdll.dll!7c9106eb()
> >       AxisXMLParser_D.dll!_heap_alloc_base(unsigned int size=28704768)  Line 212
     C
>         kernel32.dll!7c85e7af()
>         AxisXMLParser_D.dll!_CrtIsValidHeapPointer(const void * pUserData=0x026011c8)
 Line 1807        C
>         AxisXMLParser_D.dll!_free_dbg_lk(void * pUserData=0x026011c8, int nBlockUse=1)
 Line 1132 + 0x9 C
>         AxisXMLParser_D.dll!_free_dbg(void * pUserData=0x026011c8, int nBlockUse=1) 
Line 1070 + 0xd    C
>         AxisXMLParser_D.dll!free(void * pUserData=0x026011c8)  Line 1025 + 0xb  C
> 
>         AxisXMLParser_D.dll!XercesHandler::characters(const unsigned short * const chars=0x025d8440,
const unsigned int length=4)  Line 120     C++
>         xerces-c_2_5_0D.dll!xercesc_2_5::SAX2XMLReaderImpl::docCharacters(const unsigned
short * const chars=0x025d8440, const unsigned int length=4, const bool cdataSection=false)
 Line 805  C++
>         xerces-c_2_5_0D.dll!xercesc_2_5::IGXMLScanner::sendCharData(xercesc_2_5::XMLBuffer
& toSend={...})  Line 1516   C++
>         xerces-c_2_5_0D.dll!xercesc_2_5::IGXMLScanner::scanCharData(xercesc_2_5::XMLBuffer
& toUse={...})  Line 2676    C++
>         xerces-c_2_5_0D.dll!xercesc_2_5::IGXMLScanner::scanNext(xercesc_2_5::XMLPScanToken
& token={...})  Line 387     C++
>         xerces-c_2_5_0D.dll!xercesc_2_5::SAX2XMLReaderImpl::parseNext(xercesc_2_5::XMLPScanToken
& token={...})  Line 777       C++
>         AxisXMLParser_D.dll!XMLParserXerces::next(bool isCharData=true)  Line 94 + 0x1d
C++
>         AxisClient_D.dll!axiscpp::SoapDeSerializer::getElementAsString(const char * pName=0x004518c8,
const char * pNamespace=0x00000000)  Line 3048 + 0x17     C++
>         AxisClient_D.dll!axiscpp::Call::getElementAsString(const char * pName=0x004518c8,
const char * pNamespace=0x00000000)  Line 460 + 0x1c  C++
>         SpaSe_Client.exe!CSOAPClient::SendSOAPRequest(const char * endpoint=0x0012f4d0,
const char * service=0x0012f2c8, const char * method=0x0012f0c0, const char * arg=0x009e0040)
 Line 118 + 0x1b  C++
> 
> I've noticed, the crash occurs in the Xerces-Parser at the marked point:
> 
> void XercesHandler::characters(const XMLCh* const chars,
>                                const unsigned int length)
> {
>     const char* cp_PreviousNameOrValue = NULL;
>     if( m_pCurrElement && m_pCurrElement->m_pchNameOrValue)
>     {
>         if (m_pCurrElement->m_type == CHARACTER_ELEMENT)
>             cp_PreviousNameOrValue = m_pCurrElement->m_pchNameOrValue;
>     }
>     m_pCurrElement = m_pNextElement;
>     m_pNextElement->m_type = CHARACTER_ELEMENT;
> 
>     if (cp_PreviousNameOrValue)
>     {
>         char* cp_CurrentNameOrValue = XMLString::transcode(chars);
>         char* cp_FullNameOrValue  = (char*) malloc(strlen(cp_PreviousNameOrValue) + strlen(cp_CurrentNameOrValue)
+ 1);
>         cp_FullNameOrValue[0] = '\0';
>         strcat(cp_FullNameOrValue, cp_PreviousNameOrValue);
>         strcat(cp_FullNameOrValue, cp_CurrentNameOrValue);
>         m_pNextElement->m_pchNameOrValue = (const char*)cp_FullNameOrValue;
> 
> ->     free(const_cast <char*> (cp_PreviousNameOrValue));            // AFTER
THAT ERROR OCCURS
> 
>         free(cp_CurrentNameOrValue);
>     }
>     else
>         m_pNextElement->m_pchNameOrValue = XMLString::transcode(chars);
> 
> }
> 
> The vars have the following values:
> 
> cp_PreviousNameOrValue = "<?xml version="
> cp_CurrentNameOrValue = ""1.0"
> 
> After that I always encountered the same problem. When deserialising the result string
the Client-APP crashes (in malloc.c, line 212) reporting
> 
>                  Unhandled exception at 0x7c901230 in SpaSe_Client.exe: User breakpoint.
> 
> I'm using WinXP, MSVC C++ 7.1.
> 
> Am I making an error?
> Have anybody have any ideas?
> 
> Thanks for your help!
> 
> Sincerely, Nazario Cipriani.
> -- 
> Die DUMMHEIT drängt sich vor, um gesehen zu werden;
> die Klugheit steht zurück, um zu sehen.
> 'Carmen Sylva'
> ______________________________________________________________
> Verschicken Sie romantische, coole und witzige Bilder per SMS!
> Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
> 
>

Mime
View raw message