Explorar o código

Merge pull request #543 from Dmitry-Me/pointerAssertInShallowEqual

Pointer assertion
Lee Thomason %!s(int64=9) %!d(string=hai) anos
pai
achega
fc05f63575
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      tinyxml2.cpp

+ 1 - 0
tinyxml2.cpp

@@ -1133,6 +1133,7 @@ XMLNode* XMLText::ShallowClone( XMLDocument* doc ) const
 
 bool XMLText::ShallowEqual( const XMLNode* compare ) const
 {
+    TIXMLASSERT( compare );
     const XMLText* text = compare->ToText();
     return ( text && XMLUtil::StringEqual( text->Value(), Value() ) );
 }