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
e3af37eb
Commit
e3af37eb
authored
Aug 20, 2012
by
Lucas Zawacki
Committed by
Alexandre Julliard
Aug 21, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
joy.cpl: Prevent crash on IDirectInputEffect_Release.
parent
cda76337
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
main.c
dlls/joy.cpl/main.c
+3
-2
No files found.
dlls/joy.cpl/main.c
View file @
e3af37eb
...
...
@@ -90,6 +90,7 @@ static BOOL CALLBACK enum_callback(const DIDEVICEINSTANCEW *instance, void *cont
joystick
->
num_buttons
=
caps
.
dwButtons
;
joystick
->
num_axes
=
caps
.
dwAxes
;
joystick
->
forcefeedback
=
caps
.
dwFlags
&
DIDC_FORCEFEEDBACK
;
joystick
->
num_effects
=
0
;
if
(
joystick
->
forcefeedback
)
data
->
num_ff
++
;
...
...
@@ -130,10 +131,10 @@ static void destroy_joysticks(struct JoystickData *data)
for
(
i
=
0
;
i
<
data
->
num_joysticks
;
i
++
)
{
if
(
data
->
joysticks
[
i
].
forcefeedback
)
if
(
data
->
joysticks
[
i
].
forcefeedback
&&
data
->
joysticks
[
i
].
num_effects
>
0
)
{
for
(
j
=
0
;
j
<
data
->
joysticks
[
i
].
num_effects
;
j
++
)
IDirectInputEffect_Release
(
data
->
joysticks
[
i
].
effects
[
j
].
effect
);
IDirectInputEffect_Release
(
data
->
joysticks
[
i
].
effects
[
j
].
effect
);
HeapFree
(
GetProcessHeap
(),
0
,
data
->
joysticks
[
i
].
effects
);
}
...
...
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