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
bd7a12b2
Commit
bd7a12b2
authored
Jun 21, 2017
by
Matteo Bruni
Committed by
Alexandre Julliard
Jun 21, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dx9: Make the assert() in regstore_set_values() a bit more strict.
Signed-off-by:
Matteo Bruni
<
mbruni@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
362ceb2e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
preshader.c
dlls/d3dx9_36/preshader.c
+7
-4
No files found.
dlls/d3dx9_36/preshader.c
View file @
bd7a12b2
...
...
@@ -372,14 +372,17 @@ static void regstore_set_modified(struct d3dx_regstore *rs, unsigned int table,
static
void
regstore_set_values
(
struct
d3dx_regstore
*
rs
,
unsigned
int
table
,
const
void
*
data
,
unsigned
int
start_offset
,
unsigned
int
count
)
{
void
*
out
;
BYTE
*
dst
=
rs
->
tables
[
table
];
const
BYTE
*
src
=
data
;
unsigned
int
size
;
if
(
!
count
)
return
;
out
=
(
BYTE
*
)
rs
->
tables
[
table
]
+
start_offset
*
table_info
[
table
].
component_size
;
assert
(
data
!=
out
);
memcpy
(
out
,
data
,
count
*
table_info
[
table
].
component_size
);
dst
+=
start_offset
*
table_info
[
table
].
component_size
;
size
=
count
*
table_info
[
table
].
component_size
;
assert
((
src
<
dst
&&
size
<=
dst
-
src
)
||
(
src
>
dst
&&
size
<=
src
-
dst
));
memcpy
(
dst
,
src
,
size
);
regstore_set_modified
(
rs
,
table
,
start_offset
,
count
);
}
...
...
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