[ expat-Bugs-1064174 ] XML_GetBuffer / ParseBuffer bug

"SourceForge.net" <[email protected]>
Newsgroups gmane.text.xml.expat.bugs
Message-ID <[email protected]>
Bugs item #1064174, was opened at 2004-11-10 23:20
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=110127&aid=1064174&group_id=10127

Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Werner BEROUX (wernight)
Assigned to: Nobody/Anonymous (nobody)
Summary: XML_GetBuffer / ParseBuffer bug

Initial Comment:
I saw the bug by a little different code than the one
under but this one bug and can be checked really fast.

I do:
Assigne EnableStartElementHandler,
EnableEndElementHandler, EnableCharacterDataHandler().

XML_ParserCreate_MM(NULL, NULL, NULL);
XML_GetBuffer(257);
int nLength = file.Read(pszBuffer, 256);
pszBuffer[nLength] = '\0'; // Don't forget this.
XML_ParseBuffer(nLength, nLength < 257); // Returns false.

Note that when I set buffer to 512 it works. I'm
calling the XML_GetBuffer() each time in the loop and
normally I don't put a closing '\0'.

Configuration:
- I'm using CExpatImpl from CodeProject. Which is only
a wrapper.
- eXpat 1.95.8 with XML_UNICODE_WCHAR_T and XML_STATIC
defined.
- PC AMD64 - WinXP

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=110127&aid=1064174&group_id=10127
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.