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
0d1cba8e
Commit
0d1cba8e
authored
Apr 12, 2010
by
Christian Costa
Committed by
Alexandre Julliard
Apr 12, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mciqtz32: Only call CoUninitialize when CoInitializeEx succeeds.
parent
281f7018
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
mciqtz.c
dlls/mciqtz32/mciqtz.c
+4
-1
mciqtz_private.h
dlls/mciqtz32/mciqtz_private.h
+1
-0
No files found.
dlls/mciqtz32/mciqtz.c
View file @
0d1cba8e
...
@@ -153,7 +153,8 @@ static DWORD MCIQTZ_mciOpen(UINT wDevID, DWORD dwFlags,
...
@@ -153,7 +153,8 @@ static DWORD MCIQTZ_mciOpen(UINT wDevID, DWORD dwFlags,
MCIQTZ_mciStop
(
wDevID
,
MCI_WAIT
,
NULL
);
MCIQTZ_mciStop
(
wDevID
,
MCI_WAIT
,
NULL
);
CoInitializeEx
(
NULL
,
COINIT_MULTITHREADED
);
hr
=
CoInitializeEx
(
NULL
,
COINIT_MULTITHREADED
);
wma
->
uninit
=
SUCCEEDED
(
hr
);
hr
=
CoCreateInstance
(
&
CLSID_FilterGraph
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IGraphBuilder
,
(
LPVOID
*
)
&
wma
->
pgraph
);
hr
=
CoCreateInstance
(
&
CLSID_FilterGraph
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IGraphBuilder
,
(
LPVOID
*
)
&
wma
->
pgraph
);
if
(
FAILED
(
hr
))
{
if
(
FAILED
(
hr
))
{
...
@@ -197,6 +198,7 @@ err:
...
@@ -197,6 +198,7 @@ err:
IMediaControl_Release
(
wma
->
pmctrl
);
IMediaControl_Release
(
wma
->
pmctrl
);
wma
->
pmctrl
=
NULL
;
wma
->
pmctrl
=
NULL
;
if
(
wma
->
uninit
)
CoUninitialize
();
CoUninitialize
();
return
MCIERR_INTERNAL
;
return
MCIERR_INTERNAL
;
...
@@ -220,6 +222,7 @@ static DWORD MCIQTZ_mciClose(UINT wDevID, DWORD dwFlags, LPMCI_GENERIC_PARMS lpP
...
@@ -220,6 +222,7 @@ static DWORD MCIQTZ_mciClose(UINT wDevID, DWORD dwFlags, LPMCI_GENERIC_PARMS lpP
if
(
wma
->
opened
)
{
if
(
wma
->
opened
)
{
IGraphBuilder_Release
(
wma
->
pgraph
);
IGraphBuilder_Release
(
wma
->
pgraph
);
IMediaControl_Release
(
wma
->
pmctrl
);
IMediaControl_Release
(
wma
->
pmctrl
);
if
(
wma
->
uninit
)
CoUninitialize
();
CoUninitialize
();
wma
->
opened
=
FALSE
;
wma
->
opened
=
FALSE
;
}
}
...
...
dlls/mciqtz32/mciqtz_private.h
View file @
0d1cba8e
...
@@ -28,6 +28,7 @@
...
@@ -28,6 +28,7 @@
typedef
struct
{
typedef
struct
{
MCIDEVICEID
wDevID
;
MCIDEVICEID
wDevID
;
BOOL
opened
;
BOOL
opened
;
BOOL
uninit
;
IGraphBuilder
*
pgraph
;
IGraphBuilder
*
pgraph
;
IMediaControl
*
pmctrl
;
IMediaControl
*
pmctrl
;
BOOL
started
;
BOOL
started
;
...
...
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