mirror of https://github.com/AxioDL/tinyxml2.git
Merge pull request #240 from Dmitry-Me/simplifyNodeOwnershipTracking
Even more pointer pre-asserts
This commit is contained in:
commit
ee2c46928e
|
@ -669,6 +669,7 @@ void XMLNode::DeleteChild( XMLNode* node )
|
|||
|
||||
XMLNode* XMLNode::InsertEndChild( XMLNode* addThis )
|
||||
{
|
||||
TIXMLASSERT( addThis );
|
||||
if ( addThis->_document != _document ) {
|
||||
TIXMLASSERT( false );
|
||||
return 0;
|
||||
|
@ -702,6 +703,7 @@ XMLNode* XMLNode::InsertEndChild( XMLNode* addThis )
|
|||
|
||||
XMLNode* XMLNode::InsertFirstChild( XMLNode* addThis )
|
||||
{
|
||||
TIXMLASSERT( addThis );
|
||||
if ( addThis->_document != _document ) {
|
||||
TIXMLASSERT( false );
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue