Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
bbe49958
Commit
bbe49958
authored
Jun 14, 2015
by
Francois Cartegnie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
demux: mp4: don't expect cdat/cdt2 pair for eia608
parent
4f7a9d3d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
modules/demux/mp4/mp4.c
modules/demux/mp4/mp4.c
+5
-3
No files found.
modules/demux/mp4/mp4.c
View file @
bbe49958
...
@@ -430,13 +430,14 @@ static block_t * MP4_EIA608_Convert( block_t * p_block )
...
@@ -430,13 +430,14 @@ static block_t * MP4_EIA608_Convert( block_t * p_block )
{
{
/* Rebuild codec data from encap */
/* Rebuild codec data from encap */
size_t
i_copied
=
0
;
size_t
i_copied
=
0
;
size_t
i_remaining
=
p_block
->
i_buffer
;
size_t
i_remaining
=
__MIN
(
p_block
->
i_buffer
,
INT64_MAX
/
3
)
;
uint32_t
i_bytes
=
0
;
uint32_t
i_bytes
=
0
;
block_t
*
p_newblock
;
block_t
*
p_newblock
;
/* always need at least 10 bytes (atom size+header+1pair)*/
if
(
i_remaining
<
10
||
if
(
i_remaining
<
10
||
!
(
i_bytes
=
GetDWBE
(
p_block
->
p_buffer
))
||
!
(
i_bytes
=
GetDWBE
(
p_block
->
p_buffer
))
||
(
i_bytes
+
8
>
i_remaining
)
||
(
i_bytes
>
i_remaining
)
||
memcmp
(
"cdat"
,
&
p_block
->
p_buffer
[
4
],
4
)
||
memcmp
(
"cdat"
,
&
p_block
->
p_buffer
[
4
],
4
)
||
!
(
p_newblock
=
block_Alloc
(
i_remaining
*
3
-
8
))
)
!
(
p_newblock
=
block_Alloc
(
i_remaining
*
3
-
8
))
)
{
{
...
@@ -459,9 +460,10 @@ static block_t * MP4_EIA608_Convert( block_t * p_block )
...
@@ -459,9 +460,10 @@ static block_t * MP4_EIA608_Convert( block_t * p_block )
i_remaining
-=
2
;
i_remaining
-=
2
;
}
while
(
i_bytes
>=
2
);
}
while
(
i_bytes
>=
2
);
/* cdt2 is optional */
if
(
i_remaining
>=
10
&&
if
(
i_remaining
>=
10
&&
(
i_bytes
=
GetDWBE
(
p_read
))
&&
(
i_bytes
=
GetDWBE
(
p_read
))
&&
(
i_bytes
+
8
<=
i_remaining
)
&&
(
i_bytes
<=
i_remaining
)
&&
!
memcmp
(
"cdt2"
,
&
p_read
[
4
],
4
)
)
!
memcmp
(
"cdt2"
,
&
p_read
[
4
],
4
)
)
{
{
p_read
+=
8
;
p_read
+=
8
;
...
...
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