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
1a37f6e9
Commit
1a37f6e9
authored
Feb 07, 2011
by
André Hentschel
Committed by
Alexandre Julliard
Feb 08, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
oleaut32/tests: Add more safearray tests.
parent
ae3e768a
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
3 deletions
+20
-3
safearray.c
dlls/oleaut32/tests/safearray.c
+20
-3
No files found.
dlls/oleaut32/tests/safearray.c
View file @
1a37f6e9
...
...
@@ -1590,13 +1590,30 @@ static void test_SafeArrayCopy(void)
hres
=
SafeArrayAllocDescriptor
(
1
,
&
sa
);
ok
(
hres
==
S_OK
,
"SafeArrayAllocDescriptor failed with error 0x%08x
\n
"
,
hres
);
sa
->
cbElements
=
16
;
hres
=
SafeArrayCopy
(
sa
,
&
sa2
);
ok
(
hres
==
S_OK
,
"SafeArrayCopy failed with error 0x%08x
\n
"
,
hres
);
ok
(
sa
!=
sa2
,
"SafeArrayCopy performed shallow copy
\n
"
);
hres
=
SafeArrayDestroy
(
sa2
);
ok
(
hres
==
S_OK
,
"got 0x%08x
\n
"
,
hres
);
hres
=
SafeArrayDestroy
(
sa
);
ok
(
hres
==
S_OK
,
"got 0x%08x
\n
"
,
hres
);
sa2
=
(
void
*
)
0xdeadbeef
;
hres
=
SafeArrayCopy
(
NULL
,
&
sa2
);
ok
(
hres
==
S_OK
,
"SafeArrayCopy failed with error 0x%08x
\n
"
,
hres
);
ok
(
!
sa2
,
"SafeArrayCopy didn't return NULL for output array
\n
"
);
hres
=
SafeArrayAllocDescriptor
(
1
,
&
sa
);
ok
(
hres
==
S_OK
,
"SafeArrayAllocDescriptor failed with error 0x%08x
\n
"
,
hres
);
sa2
=
(
void
*
)
0xdeadbeef
;
hres
=
SafeArrayCopy
(
sa
,
&
sa2
);
ok
(
hres
==
E_INVALIDARG
,
"SafeArrayCopy with empty array should have failed with error E_INVALIDARG instead of 0x%08x
\n
"
,
hres
);
sa
->
cbElements
=
16
;
hres
=
SafeArrayCopy
(
sa
,
&
sa2
);
ok
(
hres
==
S_OK
,
"SafeArrayCopy failed with error 0x%08x
\n
"
,
hres
);
ok
(
!
sa2
,
"SafeArrayCopy didn't return NULL for output array
\n
"
);
hres
=
SafeArrayDestroy
(
sa2
);
ok
(
hres
==
S_OK
,
"got 0x%08x
\n
"
,
hres
);
...
...
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