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
927ba076
Commit
927ba076
authored
Oct 26, 2005
by
Stefan Huehner
Committed by
Alexandre Julliard
Oct 26, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix IXMLDOMDocument error handling.
parent
0518c164
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
1 deletion
+20
-1
domdoc.c
dlls/msxml3/domdoc.c
+3
-1
domdoc.c
dlls/msxml3/tests/domdoc.c
+17
-0
No files found.
dlls/msxml3/domdoc.c
View file @
927ba076
...
...
@@ -727,8 +727,10 @@ static HRESULT WINAPI domdoc_load(
return
S_FALSE
;
xmldoc
=
doread
(
filename
);
if
(
!
xmldoc
)
if
(
!
xmldoc
)
{
*
isSuccessful
=
VARIANT_FALSE
;
return
S_FALSE
;
}
This
->
node
=
create_node
(
(
xmlNodePtr
)
xmldoc
);
if
(
!
This
->
node
)
...
...
dlls/msxml3/tests/domdoc.c
View file @
927ba076
...
...
@@ -61,6 +61,10 @@ static const WCHAR szComplete4[] = {
'f'
,
'n'
,
'2'
,
'.'
,
't'
,
'x'
,
't'
,
'<'
,
'/'
,
'p'
,
'r'
,
'>'
,
'<'
,
'/'
,
'l'
,
'c'
,
'>'
,
'\n'
,
0
};
static
const
WCHAR
szNonExistentFile
[]
=
{
'c'
,
':'
,
'\\'
,
'N'
,
'o'
,
'n'
,
'e'
,
'x'
,
'i'
,
's'
,
't'
,
'e'
,
'n'
,
't'
,
'.'
,
'x'
,
'm'
,
'l'
,
0
};
static
const
WCHAR
szOpen
[]
=
{
'o'
,
'p'
,
'e'
,
'n'
,
0
};
static
const
WCHAR
szdl
[]
=
{
'd'
,
'l'
,
0
};
static
const
WCHAR
szlc
[]
=
{
'l'
,
'c'
,
0
};
...
...
@@ -77,6 +81,7 @@ void test_domdoc( void )
IXMLDOMDocument
*
doc
=
NULL
;
IXMLDOMElement
*
element
=
NULL
;
VARIANT_BOOL
b
;
VARIANT
var
;
BSTR
str
;
r
=
CoCreateInstance
(
&
CLSID_DOMDocument
,
NULL
,
...
...
@@ -93,6 +98,18 @@ void test_domdoc( void )
ok
(
r
==
S_FALSE
,
"loadXML failed
\n
"
);
ok
(
b
==
VARIANT_FALSE
,
"failed to load XML string
\n
"
);
/* try to laod an document from an non-existent file */
b
=
VARIANT_TRUE
;
str
=
SysAllocString
(
szNonExistentFile
);
VariantInit
(
&
var
);
V_VT
(
&
var
)
=
VT_BSTR
;
V_BSTR
(
&
var
)
=
str
;
r
=
IXMLDOMDocument_load
(
doc
,
var
,
&
b
);
ok
(
r
==
S_FALSE
,
"load (from file) failed
\n
"
);
ok
(
b
==
VARIANT_FALSE
,
"failed to load XML file
\n
"
);
SysFreeString
(
str
);
/* try load an empty document */
b
=
VARIANT_TRUE
;
str
=
SysAllocString
(
szEmpty
);
...
...
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