Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
cd55a674
Commit
cd55a674
authored
Sep 14, 2022
by
Nikolay Sivov
Committed by
Alexandre Julliard
Sep 15, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
xmllite/writer: Close open tag on WriteRaw().
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
parent
57497d12
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
2 deletions
+17
-2
writer.c
dlls/xmllite/tests/writer.c
+14
-2
writer.c
dlls/xmllite/writer.c
+3
-0
No files found.
dlls/xmllite/tests/writer.c
View file @
cd55a674
...
...
@@ -1320,11 +1320,23 @@ static void test_WriteRaw(void)
hr
=
IXmlWriter_Flush
(
writer
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#lx.
\n
"
,
hr
);
CHECK_OUTPUT
(
stream
,
"<?xml version=
\"
1.0
\"
encoding=
\"
UTF-8
\"
?>a<:a<:<!--a<:-->a<:<a>a</a>"
);
IStream_Release
(
stream
);
IXmlWriter_Release
(
writer
);
/* With open element. */
stream
=
writer_set_output
(
writer
);
hr
=
IXmlWriter_WriteStartElement
(
writer
,
NULL
,
L"w"
,
NULL
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#lx.
\n
"
,
hr
);
hr
=
IXmlWriter_WriteRaw
(
writer
,
L"text"
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#lx.
\n
"
,
hr
);
hr
=
IXmlWriter_Flush
(
writer
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#lx.
\n
"
,
hr
);
CHECK_OUTPUT
(
stream
,
"<w>text"
);
IStream_Release
(
stream
);
IXmlWriter_Release
(
writer
);
}
static
void
test_writer_state
(
void
)
...
...
dlls/xmllite/writer.c
View file @
cd55a674
...
...
@@ -1563,6 +1563,9 @@ static HRESULT WINAPI xmlwriter_WriteRaw(IXmlWriter *iface, LPCWSTR data)
break
;
case
XmlWriterState_InvalidEncoding
:
return
MX_E_ENCODING
;
case
XmlWriterState_ElemStarted
:
writer_close_starttag
(
This
);
break
;
default:
This
->
state
=
XmlWriterState_DocClosed
;
return
WR_E_INVALIDACTION
;
...
...
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