Module: libav Branch: master Commit: e831b3b852a23cd24f2941e68bd65299ce306880
Author: Diego Biurrun <[email protected]> Committer: Mans Rullgard <[email protected]> Date: Tue Oct 23 19:22:52 2012 +0200 av_memcpy_backptr: Drop no longer necessary malloc padding Signed-off-by: Mans Rullgard <[email protected]> --- libavcodec/dfa.c | 2 +- libavcodec/eatgv.c | 3 +-- libavcodec/lcldec.c | 3 ++- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/libavcodec/dfa.c b/libavcodec/dfa.c index 39f0f64..46051e0 100644 --- a/libavcodec/dfa.c +++ b/libavcodec/dfa.c @@ -43,7 +43,7 @@ static av_cold int dfa_decode_init(AVCodecContext *avctx) if ((ret = av_image_check_size(avctx->width, avctx->height, 0, avctx)) < 0) return ret; - s->frame_buf = av_mallocz(avctx->width * avctx->height + AV_LZO_OUTPUT_PADDING); + s->frame_buf = av_mallocz(avctx->width * avctx->height); if (!s->frame_buf) return AVERROR(ENOMEM); diff --git a/libavcodec/eatgv.c b/libavcodec/eatgv.c index b29c994..404238b 100644 --- a/libavcodec/eatgv.c +++ b/libavcodec/eatgv.c @@ -294,8 +294,7 @@ static int tgv_decode_frame(AVCodecContext *avctx, s->frame.buffer_hints = FF_BUFFER_HINTS_VALID; s->frame.linesize[0] = s->width; - /* allocate additional 12 bytes to accommodate av_memcpy_backptr() OUTBUF_PADDED optimisation */ - s->frame.data[0] = av_malloc(s->width*s->height + 12); + s->frame.data[0] = av_malloc(s->width * s->height); if (!s->frame.data[0]) return AVERROR(ENOMEM); s->frame.data[1] = av_malloc(AVPALETTE_SIZE); diff --git a/libavcodec/lcldec.c b/libavcodec/lcldec.c index 0de7410..6b101ae 100644 --- a/libavcodec/lcldec.c +++ b/libavcodec/lcldec.c @@ -476,7 +476,8 @@ static av_cold int decode_init(AVCodecContext *avctx) { LclDecContext * const c = avctx->priv_data; unsigned int basesize = avctx->width * avctx->height; - unsigned int max_basesize = FFALIGN(avctx->width, 4) * FFALIGN(avctx->height, 4) + AV_LZO_OUTPUT_PADDING; + unsigned int max_basesize = FFALIGN(avctx->width, 4) * + FFALIGN(avctx->height, 4); unsigned int max_decomp_size; if (avctx->extradata_size < 8) { _______________________________________________ libav-commits mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-commits
