Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
3b64e3ea
Commit
3b64e3ea
authored
Dec 24, 2016
by
Nicolas George
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavf/framesync: detect EOF immediately.
Fix an infinite loop in forward_status_change().
parent
68e5598e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletion
+9
-1
framesync.c
libavfilter/framesync.c
+9
-1
No files found.
libavfilter/framesync.c
View file @
3b64e3ea
...
...
@@ -18,6 +18,9 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#define FF_INTERNAL_FIELDS 1
#include "framequeue.h"
#include "libavutil/avassert.h"
#include "avfilter.h"
#include "bufferqueue.h"
...
...
@@ -314,7 +317,7 @@ int ff_framesync_filter_frame(FFFrameSync *fs, AVFilterLink *inlink,
int
ff_framesync_request_frame
(
FFFrameSync
*
fs
,
AVFilterLink
*
outlink
)
{
AVFilterContext
*
ctx
=
outlink
->
src
;
int
input
,
ret
;
int
input
,
ret
,
i
;
if
((
ret
=
ff_framesync_process_frame
(
fs
,
0
))
<
0
)
return
ret
;
...
...
@@ -323,6 +326,11 @@ int ff_framesync_request_frame(FFFrameSync *fs, AVFilterLink *outlink)
if
(
fs
->
eof
)
return
AVERROR_EOF
;
input
=
fs
->
in_request
;
/* Detect status change early */
for
(
i
=
0
;
i
<
fs
->
nb_in
;
i
++
)
if
(
!
ff_framequeue_queued_frames
(
&
ctx
->
inputs
[
i
]
->
fifo
)
&&
ctx
->
inputs
[
i
]
->
status_in
&&
!
ctx
->
inputs
[
i
]
->
status_out
)
input
=
i
;
ret
=
ff_request_frame
(
ctx
->
inputs
[
input
]);
if
(
ret
==
AVERROR_EOF
)
{
if
((
ret
=
ff_framesync_add_frame
(
fs
,
input
,
NULL
))
<
0
)
...
...
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