Initialize the pools that are part of the parser structure before
letting them get cleared. Reported by Tim Crook.
This commit is contained in:
parent
1330c4c02f
commit
5ca422d4dd
@ -678,10 +678,10 @@ XML_ParserCreate_MM(const XML_Char *encodingName,
|
|||||||
ns = XML_FALSE;
|
ns = XML_FALSE;
|
||||||
ns_triplets = XML_FALSE;
|
ns_triplets = XML_FALSE;
|
||||||
|
|
||||||
parserInit(parser, encodingName);
|
|
||||||
dtdInit(&dtd, parser);
|
|
||||||
poolInit(&tempPool, &(parser->m_mem));
|
poolInit(&tempPool, &(parser->m_mem));
|
||||||
poolInit(&temp2Pool, &(parser->m_mem));
|
poolInit(&temp2Pool, &(parser->m_mem));
|
||||||
|
parserInit(parser, encodingName);
|
||||||
|
dtdInit(&dtd, parser);
|
||||||
|
|
||||||
if (!atts || !dataBuf || (encodingName && !protocolEncodingName)) {
|
if (!atts || !dataBuf || (encodingName && !protocolEncodingName)) {
|
||||||
XML_ParserFree(parser);
|
XML_ParserFree(parser);
|
||||||
|
Loading…
Reference in New Issue
Block a user