Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
c23ce597
Commit
c23ce597
authored
Nov 28, 2012
by
Nikolay Sivov
Committed by
Alexandre Julliard
Nov 28, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
xmllite: Fix equal sign parsing.
parent
8b8fb88e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
10 deletions
+19
-10
reader.c
dlls/xmllite/reader.c
+19
-10
No files found.
dlls/xmllite/reader.c
View file @
c23ce597
...
@@ -48,7 +48,6 @@ static const WCHAR utf8W[] = {'U','T','F','-','8',0};
...
@@ -48,7 +48,6 @@ static const WCHAR utf8W[] = {'U','T','F','-','8',0};
static
const
WCHAR
dblquoteW
[]
=
{
'\"'
,
0
};
static
const
WCHAR
dblquoteW
[]
=
{
'\"'
,
0
};
static
const
WCHAR
quoteW
[]
=
{
'\''
,
0
};
static
const
WCHAR
quoteW
[]
=
{
'\''
,
0
};
static
const
WCHAR
eqW
[]
=
{
'='
,
0
};
struct
xml_encoding_data
struct
xml_encoding_data
{
{
...
@@ -515,6 +514,18 @@ static HRESULT reader_parse_versionnum(xmlreader *reader)
...
@@ -515,6 +514,18 @@ static HRESULT reader_parse_versionnum(xmlreader *reader)
return
S_OK
;
return
S_OK
;
}
}
/* [25] Eq ::= S? '=' S? */
static
HRESULT
reader_parse_eq
(
xmlreader
*
reader
)
{
static
const
WCHAR
eqW
[]
=
{
'='
,
0
};
reader_skipspaces
(
reader
);
if
(
reader_cmp
(
reader
,
eqW
))
return
WC_E_EQUAL
;
/* skip '=' */
reader_skipn
(
reader
,
1
);
reader_skipspaces
(
reader
);
return
S_OK
;
}
/* [24] VersionInfo ::= S 'version' Eq ("'" VersionNum "'" | '"' VersionNum '"') */
/* [24] VersionInfo ::= S 'version' Eq ("'" VersionNum "'" | '"' VersionNum '"') */
static
HRESULT
reader_parse_versioninfo
(
xmlreader
*
reader
)
static
HRESULT
reader_parse_versioninfo
(
xmlreader
*
reader
)
{
{
...
@@ -527,9 +538,8 @@ static HRESULT reader_parse_versioninfo(xmlreader *reader)
...
@@ -527,9 +538,8 @@ static HRESULT reader_parse_versioninfo(xmlreader *reader)
/* skip 'version' */
/* skip 'version' */
reader_skipn
(
reader
,
7
);
reader_skipn
(
reader
,
7
);
if
(
reader_cmp
(
reader
,
eqW
))
return
WC_E_EQUAL
;
hr
=
reader_parse_eq
(
reader
);
/* skip '=' */
if
(
FAILED
(
hr
))
return
hr
;
reader_skipn
(
reader
,
1
);
if
(
reader_cmp
(
reader
,
quoteW
)
&&
reader_cmp
(
reader
,
dblquoteW
))
if
(
reader_cmp
(
reader
,
quoteW
)
&&
reader_cmp
(
reader
,
dblquoteW
))
return
WC_E_QUOTE
;
return
WC_E_QUOTE
;
...
@@ -596,9 +606,8 @@ static HRESULT reader_parse_encdecl(xmlreader *reader)
...
@@ -596,9 +606,8 @@ static HRESULT reader_parse_encdecl(xmlreader *reader)
/* skip 'encoding' */
/* skip 'encoding' */
reader_skipn
(
reader
,
8
);
reader_skipn
(
reader
,
8
);
if
(
reader_cmp
(
reader
,
eqW
))
return
WC_E_EQUAL
;
hr
=
reader_parse_eq
(
reader
);
/* skip '=' */
if
(
FAILED
(
hr
))
return
hr
;
reader_skipn
(
reader
,
1
);
if
(
reader_cmp
(
reader
,
quoteW
)
&&
reader_cmp
(
reader
,
dblquoteW
))
if
(
reader_cmp
(
reader
,
quoteW
)
&&
reader_cmp
(
reader
,
dblquoteW
))
return
WC_E_QUOTE
;
return
WC_E_QUOTE
;
...
@@ -624,6 +633,7 @@ static HRESULT reader_parse_sddecl(xmlreader *reader)
...
@@ -624,6 +633,7 @@ static HRESULT reader_parse_sddecl(xmlreader *reader)
static
const
WCHAR
yesW
[]
=
{
'y'
,
'e'
,
's'
,
0
};
static
const
WCHAR
yesW
[]
=
{
'y'
,
'e'
,
's'
,
0
};
static
const
WCHAR
noW
[]
=
{
'n'
,
'o'
,
0
};
static
const
WCHAR
noW
[]
=
{
'n'
,
'o'
,
0
};
const
WCHAR
*
start
,
*
ptr
;
const
WCHAR
*
start
,
*
ptr
;
HRESULT
hr
;
if
(
!
reader_skipspaces
(
reader
))
return
WC_E_WHITESPACE
;
if
(
!
reader_skipspaces
(
reader
))
return
WC_E_WHITESPACE
;
...
@@ -631,9 +641,8 @@ static HRESULT reader_parse_sddecl(xmlreader *reader)
...
@@ -631,9 +641,8 @@ static HRESULT reader_parse_sddecl(xmlreader *reader)
/* skip 'standalone' */
/* skip 'standalone' */
reader_skipn
(
reader
,
10
);
reader_skipn
(
reader
,
10
);
if
(
reader_cmp
(
reader
,
eqW
))
return
WC_E_EQUAL
;
hr
=
reader_parse_eq
(
reader
);
/* skip '=' */
if
(
FAILED
(
hr
))
return
hr
;
reader_skipn
(
reader
,
1
);
if
(
reader_cmp
(
reader
,
quoteW
)
&&
reader_cmp
(
reader
,
dblquoteW
))
if
(
reader_cmp
(
reader
,
quoteW
)
&&
reader_cmp
(
reader
,
dblquoteW
))
return
WC_E_QUOTE
;
return
WC_E_QUOTE
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment