mirror of https://github.com/axmolengine/axmol.git
pXmlBuffer is not null terminated
This commit is contained in:
parent
5e88ecb622
commit
5443fc0d07
|
@ -66,7 +66,7 @@ static tinyxml2::XMLElement* getXMLNodeForKey(const char* pKey, tinyxml2::XMLEle
|
||||||
CCLOG("can not read xml file");
|
CCLOG("can not read xml file");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
xmlDoc->Parse(pXmlBuffer);
|
xmlDoc->Parse(pXmlBuffer, nSize);
|
||||||
delete[] pXmlBuffer;
|
delete[] pXmlBuffer;
|
||||||
// get root node
|
// get root node
|
||||||
*rootNode = xmlDoc->RootElement();
|
*rootNode = xmlDoc->RootElement();
|
||||||
|
|
Loading…
Reference in New Issue