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
79964745
Commit
79964745
authored
Oct 02, 2011
by
Laurent Aimar
Committed by
Janne Grunau
Oct 10, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
4xmdemux: prevent use of uninitialized memory
Signed-off-by:
Janne Grunau
<
janne-libav@jannau.net
>
parent
8d518a9c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
4xm.c
libavformat/4xm.c
+5
-3
No files found.
libavformat/4xm.c
View file @
79964745
...
...
@@ -173,13 +173,15 @@ static int fourxm_read_header(AVFormatContext *s,
goto
fail
;
}
if
(
current_track
+
1
>
fourxm
->
track_count
)
{
fourxm
->
track_count
=
current_track
+
1
;
fourxm
->
tracks
=
av_realloc
(
fourxm
->
tracks
,
fourxm
->
track_count
*
sizeof
(
AudioTrack
));
(
current_track
+
1
)
*
sizeof
(
AudioTrack
));
if
(
!
fourxm
->
tracks
)
{
ret
=
AVERROR
(
ENOMEM
);
ret
=
AVERROR
(
ENOMEM
);
goto
fail
;
}
memset
(
&
fourxm
->
tracks
[
fourxm
->
track_count
],
0
,
sizeof
(
AudioTrack
)
*
(
current_track
+
1
-
fourxm
->
track_count
));
fourxm
->
track_count
=
current_track
+
1
;
}
fourxm
->
tracks
[
current_track
].
adpcm
=
AV_RL32
(
&
header
[
i
+
12
]);
fourxm
->
tracks
[
current_track
].
channels
=
AV_RL32
(
&
header
[
i
+
36
]);
...
...
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