You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by "Pranav, Savkur" <Pr...@siemens.com> on 2006/11/02 06:27:37 UTC

Issues with DOmWriter::WriteToString

Hello, 
        We're using the writeToString API of DOMWriter to get back the
XML String when a root node is given. 
Following is a code snippet: 
 SaveXMLString(const XERCES_CPP_NAMESPACE::DOMNode *const p_pDOMNode) 
{ 
         

XERCES_CPP_NAMESPACE::DOMWriter         *pSerializer = 0;

 XERCES_CPP_NAMESPACE::XMLFormatTarget* pFormTarget = 0;

// get a serializer, an instance of DOMWriter
  XMLCh tempStr[100];
  XERCES_CPP_NAMESPACE::XMLString::transcode("LS", tempStr, 99);
  XERCES_CPP_NAMESPACE::DOMImplementation *impl          =
XERCES_CPP_NAMESPACE::DOMImplementationRegistry::getDOMImplementation(te
mpStr);
  pSerializer =
((XERCES_CPP_NAMESPACE::DOMImplementationLS*)impl)->createDOMWriter();

CString strRequest;

  XMLCh* pCh = pSerializer->writeToString(*p_pDOMNode);
  char *msg = XERCES_CPP_NAMESPACE::XMLString::transcode(pCh);
  strRequest= msg;
  
  XERCES_CPP_NAMESPACE::XMLString::release(&msg);
  XERCES_CPP_NAMESPACE::XMLString::release(&pCh);

}  

Memory validation tools indicate a leak in the writeToString
implementation of DomWriterImpl

 

Can any1 please let me know if there is something wrong thats being
done?



best regards,

Pranav



The new company Nokia Siemens Networks is expected to start operations
by January 1, 2007, subject to customary regulatory approvals, the
completion of standard closing conditions, and the agreement of a number
of detailed implementation steps.

Disclaimer:
This e-mail may contain trade secrets or privileged, undisclosed or
otherwise confidential information. If you have received this e-mail in
error, you are hereby notified that any review, copying or distribution
of it is strictly prohibited. Please inform us immediately and destroy
the original transmittal. Thank you for your cooperation. 

-----Original Message-----
From: Srinivasulu Gelle (JIRA) [mailto:xerces-c-dev@xml.apache.org] 
Sent: Tuesday, October 31, 2006 6:09 PM
To: c-dev@xerces.apache.org
Subject: [jira] Created: (XERCESC-1646) My Application is hanged after
calling API "xercesc_2_7::SAXParser::parse" in my code

 My Application is hanged after calling API
"xercesc_2_7::SAXParser::parse" in my code
------------------------------------------------------------------------
--------------

                 Key: XERCESC-1646
                 URL: http://issues.apache.org/jira/browse/XERCESC-1646
             Project: Xerces-C++
          Issue Type: Bug
          Components: SAX/SAX2
    Affects Versions: 2.7.0
         Environment: OS: SunOS mysunsrv  5.8 sun4u sparc
SUNW,Sun-Fire-V440 Solaris compiler :CC: Sun C++ 5.5 Patch 113817-1
            Reporter: Srinivasulu Gelle


My Application is hanged when I am calling
"xercesc_2_7::SAXParser::parse" in my progam.
When I have generated forcefully  core dump it gives core at
xercesc_2_7::MemoryManagerImpl::deallocate() function.

I there any patch required for SUnSOLARIS


-Srini



--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: c-dev-help@xerces.apache.org



The new company Nokia Siemens Networks is expected to start operations by January 1, 2007, subject to customary regulatory approvals, the completion of standard closing conditions, and the agreement of a number of detailed implementation steps.

Disclaimer:
This e-mail may contain trade secrets or privileged, undisclosed or otherwise confidential information. If you have received this e-mail in error, you are hereby notified that any review, copying or distribution of it is strictly prohibited. Please inform us immediately and destroy the original transmittal. Thank you for your cooperation.

---------------------------------------------------------------------
To unsubscribe, e-mail: c-dev-unsubscribe@xerces.apache.org
For additional commands, e-mail: c-dev-help@xerces.apache.org