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
91f9c537
Commit
91f9c537
authored
Jan 18, 2012
by
Aric Stewart
Committed by
Alexandre Julliard
Jan 18, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wineqtdecoder: Lock thing involved in streaming state in a csReceive critical section.
parent
80c233b9
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
2 deletions
+16
-2
qtsplitter.c
dlls/wineqtdecoder/qtsplitter.c
+16
-2
No files found.
dlls/wineqtdecoder/qtsplitter.c
View file @
91f9c537
...
...
@@ -163,6 +163,8 @@ typedef struct QTSplitter {
DWORD
outputSize
;
FILTER_STATE
state
;
CRITICAL_SECTION
csReceive
;
}
QTSplitter
;
static
const
IPinVtbl
QT_OutputPin_Vtbl
;
...
...
@@ -237,6 +239,9 @@ IUnknown * CALLBACK QTSplitter_create(IUnknown *punkout, HRESULT *phr)
BaseFilter_Init
(
&
This
->
filter
,
&
QT_Vtbl
,
&
CLSID_QTSplitter
,
(
DWORD_PTR
)(
__FILE__
": QTSplitter.csFilter"
),
&
BaseFuncTable
);
InitializeCriticalSection
(
&
This
->
csReceive
);
This
->
csReceive
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": QTSplitter.csReceive"
);
This
->
pVideo_Pin
=
NULL
;
This
->
pAudio_Pin
=
NULL
;
This
->
state
=
State_Stopped
;
...
...
@@ -288,6 +293,10 @@ static void QT_Destroy(QTSplitter *This)
CloseHandle
(
This
->
runEvent
);
ExitMovies
();
This
->
csReceive
.
DebugInfo
->
Spare
[
0
]
=
0
;
DeleteCriticalSection
(
&
This
->
csReceive
);
CoTaskMemFree
(
This
);
}
...
...
@@ -338,8 +347,10 @@ static HRESULT WINAPI QT_Stop(IBaseFilter *iface)
TRACE
(
"()
\n
"
);
EnterCriticalSection
(
&
This
->
csReceive
);
IAsyncReader_BeginFlush
(
This
->
pInputPin
.
pReader
);
IAsyncReader_EndFlush
(
This
->
pInputPin
.
pReader
);
LeaveCriticalSection
(
&
This
->
csReceive
);
return
S_OK
;
}
...
...
@@ -470,11 +481,13 @@ static DWORD WINAPI QTSplitter_thread(LPVOID data)
LONGLONG
mStart
=
0
,
mStop
=
0
;
float
time
;
EnterCriticalSection
(
&
This
->
csReceive
);
GetMovieNextInterestingTime
(
This
->
pQTMovie
,
nextTimeStep
,
0
,
NULL
,
movie_time
,
1
,
&
next_time
,
NULL
);
if
(
next_time
==
-
1
)
{
TRACE
(
"No next time
\n
"
);
LeaveCriticalSection
(
&
This
->
csReceive
);
break
;
}
...
...
@@ -615,6 +628,7 @@ audio_error:
TRACE
(
"No video to deliver
\n
"
);
movie_time
=
next_time
;
LeaveCriticalSection
(
&
This
->
csReceive
);
}
while
(
hr
==
S_OK
);
This
->
state
=
State_Stopped
;
...
...
@@ -634,7 +648,7 @@ static HRESULT WINAPI QT_Run(IBaseFilter *iface, REFERENCE_TIME tStart)
TRACE
(
"(%s)
\n
"
,
wine_dbgstr_longlong
(
tStart
));
EnterCriticalSection
(
&
This
->
filter
.
csFilter
);
EnterCriticalSection
(
&
This
->
csReceive
);
This
->
filter
.
rtStreamStart
=
tStart
;
if
(
This
->
pVideo_Pin
)
...
...
@@ -647,9 +661,9 @@ static HRESULT WINAPI QT_Run(IBaseFilter *iface, REFERENCE_TIME tStart)
hr_any
=
hr
;
hr
=
hr_any
;
LeaveCriticalSection
(
&
This
->
filter
.
csFilter
);
SetEvent
(
This
->
runEvent
);
LeaveCriticalSection
(
&
This
->
csReceive
);
return
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