2017-11-28 21:32 GMT+01:00 Michael Niedermayer <[email protected]>:
> On Mon, Nov 27, 2017 at 05:24:14AM +0100, Carl Eugen Hoyos wrote:
>> for (i = 0; i < entries && !pb->eof_reached; i++) {
>> - int sample_duration;
>> + int sample_duration, ret;
>> unsigned int sample_count;
>> + if (i > sc->stts_count) {
>> + ret = av_reallocp_array(&sc->stts_data,
>> + FFMIN(sc->stts_count * 2LL, entries),
>> + sizeof(*sc->stts_data));
>
> this should use a variant of av_fast_realloc
Do you prefer the new patch?
The old variant here looks slightly saner to me.
Carl Eugen
_______________________________________________
ffmpeg-devel mailing list
[email protected]
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel