On Sun, Jan 26, 2020 at 4:54 PM James Almer <jamr...@gmail.com> wrote:
> On 1/23/2020 1:08 PM, Andreas Rheinhardt wrote: > > > > + buf = av_malloc((size_t)len + AV_INPUT_BUFFER_PADDING_SIZE); > > We never cast the arguments to av_malloc() to size_t, and len here is > guaranteed to be <= size by parse_obu_header(), so it's unnecessary. > > Removed it and pushed the patch. Thanks. > The input data currently always comes from a packet, so that its size is <= INT_MAX - AV_INPUT_BUFFER_PADDING_SIZE, but there is no requirement that this always has to be that way. So I added the cast in order to make sure that no overflow happens during the addition. But I guess it's not important. - Andreas PS: None of the current callers needs the output to be padded, but I nevertheless retained it. _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".