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
948202c4
Commit
948202c4
authored
Mar 16, 2015
by
Stefan Dösinger
Committed by
Alexandre Julliard
Mar 17, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ddraw: Add validation and tests for DDBLT_ROP.
parent
e0edd55a
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
0 deletions
+16
-0
surface.c
dlls/ddraw/surface.c
+16
-0
ddraw7.c
dlls/ddraw/tests/ddraw7.c
+0
-0
No files found.
dlls/ddraw/surface.c
View file @
948202c4
...
@@ -1539,6 +1539,12 @@ static HRESULT WINAPI ddraw_surface7_Blt(IDirectDrawSurface7 *iface, RECT *DestR
...
@@ -1539,6 +1539,12 @@ static HRESULT WINAPI ddraw_surface7_Blt(IDirectDrawSurface7 *iface, RECT *DestR
if
(
Flags
&
(
DDBLT_COLORFILL
|
DDBLT_DEPTHFILL
))
if
(
Flags
&
(
DDBLT_COLORFILL
|
DDBLT_DEPTHFILL
))
{
{
if
(
Flags
&
DDBLT_ROP
)
{
wined3d_mutex_unlock
();
WARN
(
"DDBLT_ROP used with DDBLT_COLORFILL or DDBLT_DEPTHFILL, returning DDERR_INVALIDPARAMS.
\n
"
);
return
DDERR_INVALIDPARAMS
;
}
if
(
src_surface
)
if
(
src_surface
)
{
{
wined3d_mutex_unlock
();
wined3d_mutex_unlock
();
...
@@ -1569,6 +1575,16 @@ static HRESULT WINAPI ddraw_surface7_Blt(IDirectDrawSurface7 *iface, RECT *DestR
...
@@ -1569,6 +1575,16 @@ static HRESULT WINAPI ddraw_surface7_Blt(IDirectDrawSurface7 *iface, RECT *DestR
}
}
}
}
if
(
Flags
&
DDBLT_ROP
)
{
if
(
!
DDBltFx
)
{
wined3d_mutex_unlock
();
WARN
(
"DDBLT_ROP used with DDBltFx = NULL, returning DDERR_INVALIDPARAMS.
\n
"
);
return
DDERR_INVALIDPARAMS
;
}
}
if
(
Flags
&
DDBLT_KEYSRC
&&
(
!
src_surface
||
!
(
src_surface
->
surface_desc
.
dwFlags
&
DDSD_CKSRCBLT
)))
if
(
Flags
&
DDBLT_KEYSRC
&&
(
!
src_surface
||
!
(
src_surface
->
surface_desc
.
dwFlags
&
DDSD_CKSRCBLT
)))
{
{
WARN
(
"DDBLT_KEYDEST blit without color key in surface, returning DDERR_INVALIDPARAMS
\n
"
);
WARN
(
"DDBLT_KEYDEST blit without color key in surface, returning DDERR_INVALIDPARAMS
\n
"
);
...
...
dlls/ddraw/tests/ddraw7.c
View file @
948202c4
This diff is collapsed.
Click to expand it.
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