On 07/29/2011 06:29 PM, Alex Converse wrote:
> This prevents out of bounds reads when extradata is being decoded.
> ---
> libavformat/mxfdec.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/libavformat/mxfdec.c b/libavformat/mxfdec.c
> index e2688b1..8906bdd 100644
> --- a/libavformat/mxfdec.c
> +++ b/libavformat/mxfdec.c
> @@ -600,7 +600,7 @@ static int mxf_read_generic_descriptor(void *arg,
> AVIOContext *pb, int tag, int
> default:
> /* Private uid used by SONY C0023S01.mxf */
> if (IS_KLV_KEY(uid, mxf_sony_mpeg4_extradata)) {
> - descriptor->extradata = av_malloc(size);
> + descriptor->extradata = av_malloc(size +
> FF_INPUT_BUFFER_PADDING_SIZE);
> if (!descriptor->extradata)
> return -1;
> descriptor->extradata_size = size;
looks good.
-Justin
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel