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
379c6564
Commit
379c6564
authored
Mar 10, 2014
by
Stefan Dösinger
Committed by
Alexandre Julliard
Mar 11, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d9/tests: Show that a failing SetPrivateData call does not clear the old contents.
parent
ab6368b6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
0 deletions
+15
-0
device.c
dlls/d3d9/tests/device.c
+15
-0
No files found.
dlls/d3d9/tests/device.c
View file @
379c6564
...
...
@@ -5109,6 +5109,20 @@ static void test_private_data(void)
device
,
sizeof
(
IUnknown
*
)
*
2
,
D3DSPD_IUNKNOWN
);
ok
(
hr
==
D3DERR_INVALIDCALL
,
"Got unexpected hr %#x.
\n
"
,
hr
);
/* A failing SetPrivateData call does not clear the old data with the same tag. */
hr
=
IDirect3DSurface9_SetPrivateData
(
surface
,
&
IID_IDirect3DVertexBuffer9
,
device
,
sizeof
(
device
),
D3DSPD_IUNKNOWN
);
ok
(
SUCCEEDED
(
hr
),
"Failed to set private data, hr %#x.
\n
"
,
hr
);
hr
=
IDirect3DSurface9_SetPrivateData
(
surface
,
&
IID_IDirect3DVertexBuffer9
,
device
,
sizeof
(
device
)
*
2
,
D3DSPD_IUNKNOWN
);
ok
(
hr
==
D3DERR_INVALIDCALL
,
"Got unexpected hr %#x.
\n
"
,
hr
);
size
=
sizeof
(
ptr
);
hr
=
IDirect3DSurface9_GetPrivateData
(
surface
,
&
IID_IDirect3DVertexBuffer9
,
&
ptr
,
&
size
);
ok
(
SUCCEEDED
(
hr
),
"Failed to get private data, hr %#x.
\n
"
,
hr
);
IUnknown_Release
(
ptr
);
hr
=
IDirect3DSurface9_FreePrivateData
(
surface
,
&
IID_IDirect3DVertexBuffer9
);
ok
(
SUCCEEDED
(
hr
),
"Failed to free private data, hr %#x.
\n
"
,
hr
);
refcount
=
get_refcount
((
IUnknown
*
)
device
);
hr
=
IDirect3DSurface9_SetPrivateData
(
surface
,
&
IID_IDirect3DSurface9
/* Abuse this tag */
,
device
,
sizeof
(
IUnknown
*
),
D3DSPD_IUNKNOWN
);
...
...
@@ -5176,6 +5190,7 @@ static void test_private_data(void)
ok
(
SUCCEEDED
(
hr
),
"Failed to set private data, hr %#x.
\n
"
,
hr
);
hr
=
IDirect3DSurface9_GetPrivateData
(
surface2
,
&
IID_IDirect3DVertexBuffer9
,
data
,
&
size
);
ok
(
hr
==
D3DERR_NOTFOUND
,
"Got unexpected hr %#x.
\n
"
,
hr
);
hr
=
IDirect3DSurface9_FreePrivateData
(
surface
,
&
IID_IDirect3DVertexBuffer9
);
ok
(
SUCCEEDED
(
hr
),
"Failed to free private data, hr %#x.
\n
"
,
hr
);
...
...
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