Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
external
ffmpeg
Commits
1e5c667c
Commit
1e5c667c
authored
Oct 04, 2002
by
Fabrice Bellard
Browse files
fixed MPEG2 pts parsing - ignore unknown stream type
Originally committed as revision 1001 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
7be166e4
Changes
1
Hide whitespace changes
Inline
Side-by-side
libav/mpeg.c
View file @
1e5c667c
...
...
@@ -555,7 +555,7 @@ static int mpegps_read_packet(AVFormatContext *s,
len
-=
2
;
if
(
header_len
>
len
)
goto
redo
;
if
((
flags
&
0xc0
)
==
0x
4
0
)
{
if
((
flags
&
0xc0
)
==
0x
8
0
)
{
pts
=
get_pts
(
&
s
->
pb
,
-
1
);
dts
=
pts
;
header_len
-=
5
;
...
...
@@ -590,10 +590,6 @@ static int mpegps_read_packet(AVFormatContext *s,
if
(
st
->
id
==
startcode
)
goto
found
;
}
/* no stream found: add a new stream */
st
=
av_new_stream
(
s
,
startcode
);
if
(
!
st
)
goto
skip
;
if
(
startcode
>=
0x1e0
&&
startcode
<=
0x1ef
)
{
type
=
CODEC_TYPE_VIDEO
;
codec_id
=
CODEC_ID_MPEG1VIDEO
;
...
...
@@ -609,6 +605,10 @@ static int mpegps_read_packet(AVFormatContext *s,
url_fskip
(
&
s
->
pb
,
len
);
goto
redo
;
}
/* no stream found: add a new stream */
st
=
av_new_stream
(
s
,
startcode
);
if
(
!
st
)
goto
skip
;
st
->
codec
.
codec_type
=
type
;
st
->
codec
.
codec_id
=
codec_id
;
found:
...
...
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