[FFmpeg-devel] [PATCH 1/2] libx265: Simple cosmetic and log message fix
Derek Buitenhuis
derek.buitenhuis at gmail.com
Sun Mar 23 15:40:59 CET 2014
Signed-off-by: Derek Buitenhuis <derek.buitenhuis at gmail.com>
---
libavcodec/libx265.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/libavcodec/libx265.c b/libavcodec/libx265.c
index 2aceac7..ba738c6 100644
--- a/libavcodec/libx265.c
+++ b/libavcodec/libx265.c
@@ -193,7 +193,8 @@ static av_cold int libx265_encode_init(AVCodecContext *avctx)
ctx->header = av_malloc(ctx->header_size + FF_INPUT_BUFFER_PADDING_SIZE);
if (!ctx->header) {
av_log(avctx, AV_LOG_ERROR,
- "Cannot allocate HEVC header of size %d.\n", ctx->header_size);
+ "Cannot allocate HEVC header of size %d (%d with padding).\n",
+ ctx->header_size, ctx->header_size + FF_INPUT_BUFFER_PADDING_SIZE);
libx265_encode_close(avctx);
return AVERROR(ENOMEM);
}
@@ -206,9 +207,10 @@ static av_cold int libx265_encode_init(AVCodecContext *avctx)
if (avctx->flags & CODEC_FLAG_GLOBAL_HEADER) {
avctx->extradata_size = ctx->header_size;
- avctx->extradata = ctx->header;
+ avctx->extradata = ctx->header;
+
ctx->header_size = 0;
- ctx->header = NULL;
+ ctx->header = NULL;
}
return 0;
--
1.9.0
More information about the ffmpeg-devel
mailing list