mirror of
https://github.com/reactos/reactos.git
synced 2025-07-25 04:03:56 +00:00
parse, but ignore, <? ?> tags - eliminated duplicate code ala FixSeparator() - fix path separator issues
svn path=/branches/xmlbuildsystem/; revision=12868
This commit is contained in:
parent
f7257ee1be
commit
4e235dbcc9
8 changed files with 53 additions and 45 deletions
|
@ -251,6 +251,14 @@ XMLFile::get_token(string& token)
|
|||
else
|
||||
tokend += 3;
|
||||
}
|
||||
else if ( !strncmp ( _p, "<?", 2 ) )
|
||||
{
|
||||
tokend = strstr ( _p, "?>" );
|
||||
if ( !tokend )
|
||||
tokend = _end;
|
||||
else
|
||||
tokend += 2;
|
||||
}
|
||||
else if ( *_p == '<' )
|
||||
{
|
||||
tokend = strchr ( _p, '>' );
|
||||
|
@ -456,7 +464,9 @@ XMLParse(XMLFile& f,
|
|||
return NULL;
|
||||
bool end_tag;
|
||||
|
||||
while ( token[0] != '<' || !strncmp ( token.c_str(), "<!--", 4 ) )
|
||||
while ( token[0] != '<'
|
||||
|| !strncmp ( token.c_str(), "<!--", 4 )
|
||||
|| !strncmp ( token.c_str(), "<?", 2 ) )
|
||||
{
|
||||
if ( token[0] != '<' )
|
||||
throw XMLSyntaxErrorException ( f.Location(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue