History

avfilter/avcodec: Use av_mallocz_array()

Michael Niedermayer committed 12 years ago

Commit 2c4862e1 parent 0bfb1e91 file · +1 −1Browse files

Showing the changes to libavfilter/avcodec.c (1 of 1 file). Show all

Unified · Split

libavfilter/avcodec.c+1−1
@@ -116,7 +116,7 @@ int avfilter_copy_buf_props(AVFrame *dst, const AVFilterBufferRef *src) · 115 unmodified lines
116116 planes = av_sample_fmt_is_planar(src->format) ? nb_channels : 1;
117117
118118 if (planes > FF_ARRAY_ELEMS(dst->data)) {
119− dst->extended_data = av_mallocz(planes * sizeof(*dst->extended_data));
119+ dst->extended_data = av_mallocz_array(planes, sizeof(*dst->extended_data));
120120 if (!dst->extended_data)
121121 return AVERROR(ENOMEM);
122122 memcpy(dst->extended_data, src->extended_data,

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t