Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
X
x264
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
8
Issues
8
List
Boards
Labels
Service Desk
Milestones
Merge Requests
9
Merge Requests
9
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
VideoLAN
x264
Commits
cb94c2bd
Commit
cb94c2bd
authored
May 31, 2010
by
Anton Mitrofanov
Committed by
Fiona Glaser
May 31, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix crash with MP4-muxing if zero frames were encoded
parent
16adb517
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
output/mp4.c
output/mp4.c
+2
-1
No files found.
output/mp4.c
View file @
cb94c2bd
...
@@ -112,6 +112,7 @@ static int close_file( hnd_t handle, int64_t largest_pts, int64_t second_largest
...
@@ -112,6 +112,7 @@ static int close_file( hnd_t handle, int64_t largest_pts, int64_t second_largest
if
(
p_mp4
->
p_sample
->
data
)
if
(
p_mp4
->
p_sample
->
data
)
free
(
p_mp4
->
p_sample
->
data
);
free
(
p_mp4
->
p_sample
->
data
);
p_mp4
->
p_sample
->
dataLength
=
0
;
gf_isom_sample_del
(
&
p_mp4
->
p_sample
);
gf_isom_sample_del
(
&
p_mp4
->
p_sample
);
}
}
...
@@ -135,7 +136,7 @@ static int close_file( hnd_t handle, int64_t largest_pts, int64_t second_largest
...
@@ -135,7 +136,7 @@ static int close_file( hnd_t handle, int64_t largest_pts, int64_t second_largest
* The reason is that an Edit Box maps the presentation time-line to the media time-line.
* The reason is that an Edit Box maps the presentation time-line to the media time-line.
* Any demuxers should follow the Edit Box if it exists. */
* Any demuxers should follow the Edit Box if it exists. */
GF_ISOSample
*
sample
=
gf_isom_get_sample_info
(
p_mp4
->
p_file
,
p_mp4
->
i_track
,
1
,
NULL
,
NULL
);
GF_ISOSample
*
sample
=
gf_isom_get_sample_info
(
p_mp4
->
p_file
,
p_mp4
->
i_track
,
1
,
NULL
,
NULL
);
if
(
sample
->
CTS_Offset
>
0
)
if
(
sample
&&
sample
->
CTS_Offset
>
0
)
{
{
uint32_t
mvhd_timescale
=
gf_isom_get_timescale
(
p_mp4
->
p_file
);
uint32_t
mvhd_timescale
=
gf_isom_get_timescale
(
p_mp4
->
p_file
);
uint64_t
tkhd_duration
=
(
uint64_t
)(
mdhd_duration
*
(
(
double
)
mvhd_timescale
/
p_mp4
->
i_time_res
)
);
uint64_t
tkhd_duration
=
(
uint64_t
)(
mdhd_duration
*
(
(
double
)
mvhd_timescale
/
p_mp4
->
i_time_res
)
);
...
...
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