Browse Source

Merge pull request #538 from Dmitry-Me/suppressC6011

Suppress C6011 code analysis false positive warning
Lee Thomason 9 năm trước cách đây
mục cha
commit
395ea09f83
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  1. 1 0
      tinyxml2.cpp

+ 1 - 0
tinyxml2.cpp

@@ -1838,6 +1838,7 @@ XMLAttribute* XMLElement::CreateAttribute()
 {
     TIXMLASSERT( sizeof( XMLAttribute ) == _document->_attributePool.ItemSize() );
     XMLAttribute* attrib = new (_document->_attributePool.Alloc() ) XMLAttribute();
+    TIXMLASSERT( attrib );
     attrib->_memPool = &_document->_attributePool;
     attrib->_memPool->SetTracked();
     return attrib;