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
5989a2b2
Commit
5989a2b2
authored
Jan 15, 2015
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avcodec/g722enc: Use av_mallocz_array()
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
71bd6ea0
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
g722enc.c
libavcodec/g722enc.c
+3
-3
No files found.
libavcodec/g722enc.c
View file @
5989a2b2
...
...
@@ -75,9 +75,9 @@ static av_cold int g722_encode_init(AVCodecContext * avctx)
int
max_paths
=
frontier
*
FREEZE_INTERVAL
;
int
i
;
for
(
i
=
0
;
i
<
2
;
i
++
)
{
c
->
paths
[
i
]
=
av_mallocz
(
max_paths
*
sizeof
(
**
c
->
paths
));
c
->
node_buf
[
i
]
=
av_mallocz
(
2
*
frontier
*
sizeof
(
**
c
->
node_buf
));
c
->
nodep_buf
[
i
]
=
av_mallocz
(
2
*
frontier
*
sizeof
(
**
c
->
nodep_buf
));
c
->
paths
[
i
]
=
av_mallocz
_array
(
max_paths
,
sizeof
(
**
c
->
paths
));
c
->
node_buf
[
i
]
=
av_mallocz
_array
(
frontier
,
2
*
sizeof
(
**
c
->
node_buf
));
c
->
nodep_buf
[
i
]
=
av_mallocz
_array
(
frontier
,
2
*
sizeof
(
**
c
->
nodep_buf
));
if
(
!
c
->
paths
[
i
]
||
!
c
->
node_buf
[
i
]
||
!
c
->
nodep_buf
[
i
])
{
ret
=
AVERROR
(
ENOMEM
);
goto
error
;
...
...
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