소스 검색

Test parsing result as early as possible

Dmitry-Me 8 년 전
부모
커밋
aea64c4b75
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      xmltest.cpp

+ 2 - 2
xmltest.cpp

@@ -1774,9 +1774,9 @@ int main( int argc, const char ** argv )
 		// an interesting test case.
 		XMLDocument doc;
 		XMLError err = doc.Parse(xml);
-		XMLElement* playlist = doc.FirstChildElement("playlist");
-
 		XMLTest("Crash bug parsing", err, XML_SUCCESS);
+
+		XMLElement* playlist = doc.FirstChildElement("playlist");
 		XMLTest("Crash bug parsing", true, playlist != 0);
 
 		tinyxml2::XMLElement* entry = playlist->FirstChildElement("entry");