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
f6deca59
Commit
f6deca59
authored
Aug 29, 2023
by
Rémi Bernon
Committed by
Alexandre Julliard
Sep 06, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dmsynth: Return S_FALSE if IDirectMusicSynth_Activate is no-op.
parent
722262b0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
9 deletions
+4
-9
synth.c
dlls/dmsynth/synth.c
+2
-7
dmsynth.c
dlls/dmsynth/tests/dmsynth.c
+2
-2
No files found.
dlls/dmsynth/synth.c
View file @
f6deca59
...
...
@@ -422,16 +422,11 @@ static HRESULT WINAPI synth_Activate(IDirectMusicSynth8 *iface, BOOL enable)
TRACE
(
"(%p)->(%d)
\n
"
,
This
,
enable
);
if
(
enable
==
This
->
active
)
return
S_FALSE
;
if
(
!
This
->
sink
)
return
DMUS_E_NOSYNTHSINK
;
if
(
enable
==
This
->
active
)
{
if
(
enable
)
return
DMUS_E_SYNTHACTIVE
;
else
return
S_FALSE
;
}
if
((
hr
=
IDirectMusicSynthSink_Activate
(
This
->
sink
,
enable
))
!=
S_OK
)
{
if
(
hr
==
DMUS_E_SYNTHACTIVE
||
hr
==
S_FALSE
)
WARN
(
"Synth and sink active state out of sync. Fixing.
\n
"
);
...
...
dlls/dmsynth/tests/dmsynth.c
View file @
f6deca59
...
...
@@ -1007,7 +1007,7 @@ static void test_IDirectMusicSynth(void)
hr
=
IDirectMusicSynth_Activate
(
synth
,
TRUE
);
ok
(
hr
==
DMUS_E_NOSYNTHSINK
,
"got %#lx
\n
"
,
hr
);
hr
=
IDirectMusicSynth_Activate
(
synth
,
FALSE
);
todo_wine
ok
(
hr
==
S_FALSE
,
"got %#lx
\n
"
,
hr
);
ok
(
hr
==
S_FALSE
,
"got %#lx
\n
"
,
hr
);
hr
=
IDirectMusicSynth_SetSynthSink
(
synth
,
NULL
);
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
...
...
@@ -1034,7 +1034,7 @@ static void test_IDirectMusicSynth(void)
hr
=
IDirectMusicSynth_Activate
(
synth
,
TRUE
);
todo_wine
ok
(
hr
==
S_OK
,
"got %#lx
\n
"
,
hr
);
hr
=
IDirectMusicSynth_Activate
(
synth
,
TRUE
);
todo_wine
ok
(
hr
==
S_FALSE
,
"got %#lx
\n
"
,
hr
);
ok
(
hr
==
S_FALSE
,
"got %#lx
\n
"
,
hr
);
/* Close is fine while active */
hr
=
IDirectMusicSynth_Close
(
synth
);
...
...
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