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
d8781586
Commit
d8781586
authored
Jan 20, 2022
by
Henri Verbeet
Committed by
Alexandre Julliard
Jan 20, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Properly compare integers in wined3d_so_desc_compare().
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
9b98d86f
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
9 deletions
+9
-9
device.c
dlls/wined3d/device.c
+9
-9
No files found.
dlls/wined3d/device.c
View file @
d8781586
...
...
@@ -5733,11 +5733,11 @@ static int wined3d_so_desc_compare(const void *key, const struct wine_rb_entry *
unsigned
int
i
;
int
ret
;
if
((
ret
=
(
k
->
element_count
-
desc
->
element_count
)))
if
((
ret
=
wined3d_uint32_compare
(
k
->
element_count
,
desc
->
element_count
)))
return
ret
;
if
((
ret
=
(
k
->
buffer_stride_count
-
desc
->
buffer_stride_count
)))
if
((
ret
=
wined3d_uint32_compare
(
k
->
buffer_stride_count
,
desc
->
buffer_stride_count
)))
return
ret
;
if
((
ret
=
(
k
->
rasterizer_stream_idx
-
desc
->
rasterizer_stream_idx
)))
if
((
ret
=
wined3d_uint32_compare
(
k
->
rasterizer_stream_idx
,
desc
->
rasterizer_stream_idx
)))
return
ret
;
for
(
i
=
0
;
i
<
k
->
element_count
;
++
i
)
...
...
@@ -5745,25 +5745,25 @@ static int wined3d_so_desc_compare(const void *key, const struct wine_rb_entry *
const
struct
wined3d_stream_output_element
*
b
=
&
desc
->
elements
[
i
];
const
struct
wined3d_stream_output_element
*
a
=
&
k
->
elements
[
i
];
if
((
ret
=
(
a
->
stream_idx
-
b
->
stream_idx
)))
if
((
ret
=
wined3d_uint32_compare
(
a
->
stream_idx
,
b
->
stream_idx
)))
return
ret
;
if
((
ret
=
(
!
a
->
semantic_name
-
!
b
->
semantic_name
)))
return
ret
;
if
(
a
->
semantic_name
&&
(
ret
=
strcmp
(
a
->
semantic_name
,
b
->
semantic_name
)))
return
ret
;
if
((
ret
=
(
a
->
semantic_idx
-
b
->
semantic_idx
)))
if
((
ret
=
wined3d_uint32_compare
(
a
->
semantic_idx
,
b
->
semantic_idx
)))
return
ret
;
if
((
ret
=
(
a
->
component_idx
-
b
->
component_idx
)))
if
((
ret
=
wined3d_uint32_compare
(
a
->
component_idx
,
b
->
component_idx
)))
return
ret
;
if
((
ret
=
(
a
->
component_count
-
b
->
component_count
)))
if
((
ret
=
wined3d_uint32_compare
(
a
->
component_count
,
b
->
component_count
)))
return
ret
;
if
((
ret
=
(
a
->
output_slot
-
b
->
output_slot
)))
if
((
ret
=
wined3d_uint32_compare
(
a
->
output_slot
,
b
->
output_slot
)))
return
ret
;
}
for
(
i
=
0
;
i
<
k
->
buffer_stride_count
;
++
i
)
{
if
((
ret
=
(
k
->
buffer_strides
[
i
]
-
desc
->
buffer_strides
[
i
])))
if
((
ret
=
wined3d_uint32_compare
(
k
->
buffer_strides
[
i
],
desc
->
buffer_strides
[
i
])))
return
ret
;
}
...
...
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