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
10fa50c1
Commit
10fa50c1
authored
Feb 24, 2016
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avcodec/mpeg12dec: Fix missing slice handling without padding
Signed-off-by:
Michael Niedermayer
<
michael@niedermayer.cc
>
parent
4170a44b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
mpeg12dec.c
libavcodec/mpeg12dec.c
+5
-3
No files found.
libavcodec/mpeg12dec.c
View file @
10fa50c1
...
...
@@ -1871,6 +1871,7 @@ static int mpeg_decode_slice(MpegEncContext *s, int mb_y,
if
(
++
s
->
mb_x
>=
s
->
mb_width
)
{
const
int
mb_size
=
16
>>
s
->
avctx
->
lowres
;
int
left
;
ff_mpeg_draw_horiz_band
(
s
,
mb_size
*
(
s
->
mb_y
>>
field_pic
),
mb_size
);
ff_mpv_report_decode_progress
(
s
);
...
...
@@ -1910,12 +1911,13 @@ static int mpeg_decode_slice(MpegEncContext *s, int mb_y,
// in cases where the slice is completely outside the visible
// area, we detect this here instead of running into the end expecting
// more data
left
=
get_bits_left
(
&
s
->
gb
);
if
(
s
->
mb_y
>=
((
s
->
height
+
15
)
>>
4
)
&&
!
s
->
progressive_sequence
&&
get_bits_left
(
&
s
->
gb
)
<=
8
&&
get_bits_left
(
&
s
->
gb
)
>=
0
&&
left
<=
25
&&
left
>=
0
&&
s
->
mb_skip_run
==
-
1
&&
show_bits
(
&
s
->
gb
,
8
)
==
0
)
(
!
left
||
show_bits
(
&
s
->
gb
,
left
)
==
0
)
)
goto
eos
;
ff_init_block_index
(
s
);
...
...
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