Order patterns the same way they are searched

This commit is contained in:
Dmitry-Me 2015-03-30 09:54:36 +03:00
parent 28c7c8c14f
commit c505e136da
1 changed files with 2 additions and 2 deletions

View File

@ -550,14 +550,14 @@ char* XMLDocument::Identify( char* p, XMLNode** node )
// These strings define the matching patters:
static const char* xmlHeader = { "<?" };
static const char* commentHeader = { "<!--" };
static const char* dtdHeader = { "<!" };
static const char* cdataHeader = { "<![CDATA[" };
static const char* dtdHeader = { "<!" };
static const char* elementHeader = { "<" }; // and a header for everything else; check last.
static const int xmlHeaderLen = 2;
static const int commentHeaderLen = 4;
static const int dtdHeaderLen = 2;
static const int cdataHeaderLen = 9;
static const int dtdHeaderLen = 2;
static const int elementHeaderLen = 1;
TIXMLASSERT( sizeof( XMLComment ) == sizeof( XMLUnknown ) ); // use same memory pool