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
b3461c48
Commit
b3461c48
authored
Nov 20, 2020
by
Nikolay Sivov
Committed by
Alexandre Julliard
Nov 20, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mf/session: Shutdown and release presentation clock on session shutdown.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
b8e550a5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
1 deletion
+20
-1
session.c
dlls/mf/session.c
+3
-0
mf.c
dlls/mf/tests/mf.c
+17
-1
No files found.
dlls/mf/session.c
View file @
b3461c48
...
...
@@ -1792,6 +1792,9 @@ static HRESULT WINAPI mfsession_Shutdown(IMFMediaSession *iface)
IMFMediaEventQueue_Shutdown
(
session
->
event_queue
);
if
(
session
->
quality_manager
)
IMFQualityManager_Shutdown
(
session
->
quality_manager
);
MFShutdownObject
((
IUnknown
*
)
session
->
clock
);
IMFPresentationClock_Release
(
session
->
clock
);
session
->
clock
=
NULL
;
}
LeaveCriticalSection
(
&
session
->
cs
);
...
...
dlls/mf/tests/mf.c
View file @
b3461c48
...
...
@@ -1188,13 +1188,14 @@ static void test_media_session(void)
IMFAttributes
*
attributes
;
IMFMediaSession
*
session
;
IMFTopology
*
topology
;
IMFShutdown
*
shutdown
;
PROPVARIANT
propvar
;
DWORD
status
,
caps
;
IMFGetService
*
gs
;
IMFClock
*
clock
;
IUnknown
*
unk
;
HRESULT
hr
;
float
rate
;
DWORD
caps
;
BOOL
thin
;
hr
=
MFStartup
(
MF_VERSION
,
MFSTARTUP_FULL
);
...
...
@@ -1275,9 +1276,24 @@ todo_wine
hr
=
MFCreateMediaSession
(
NULL
,
&
session
);
ok
(
hr
==
S_OK
,
"Failed to create media session, hr %#x.
\n
"
,
hr
);
hr
=
IMFMediaSession_GetClock
(
session
,
&
clock
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMFClock_QueryInterface
(
clock
,
&
IID_IMFShutdown
,
(
void
**
)
&
shutdown
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMFShutdown_GetShutdownStatus
(
shutdown
,
&
status
);
ok
(
hr
==
MF_E_INVALIDREQUEST
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMFMediaSession_Shutdown
(
session
);
ok
(
hr
==
S_OK
,
"Failed to shut down, hr %#x.
\n
"
,
hr
);
hr
=
IMFShutdown_GetShutdownStatus
(
shutdown
,
&
status
);
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
ok
(
status
==
MFSHUTDOWN_COMPLETED
,
"Unexpected shutdown status %u.
\n
"
,
status
);
IMFShutdown_Release
(
shutdown
);
hr
=
IMFMediaSession_ClearTopologies
(
session
);
ok
(
hr
==
MF_E_SHUTDOWN
,
"Unexpected hr %#x.
\n
"
,
hr
);
...
...
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