summaryrefslogtreecommitdiffstats
path: root/libavcodec/h264_mp4toannexb_bsf.c
diff options
context:
space:
mode:
authorLuca Barbato <lu_zero@gentoo.org>2013-06-11 17:57:31 +0200
committerLuca Barbato <lu_zero@gentoo.org>2013-06-15 16:14:45 +0200
commit9e80eda26d06c7c48dbec5dfe643c857c62c0ee7 (patch)
tree06970e1c7122afeb8811b6fef1154e1039c07720 /libavcodec/h264_mp4toannexb_bsf.c
parent8d929afd256069aa881f2bf58ef9f0ffce2d6b7e (diff)
downloadffmpeg-streaming-9e80eda26d06c7c48dbec5dfe643c857c62c0ee7.zip
ffmpeg-streaming-9e80eda26d06c7c48dbec5dfe643c857c62c0ee7.tar.gz
h264_mp4toannexb_bsf: return a padded buffer
The code using the returned buffer might expect it to be FF_INPUT_BUFFER_PADDING_SIZE padded as any other avpacket.
Diffstat (limited to 'libavcodec/h264_mp4toannexb_bsf.c')
-rw-r--r--libavcodec/h264_mp4toannexb_bsf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/h264_mp4toannexb_bsf.c b/libavcodec/h264_mp4toannexb_bsf.c
index 86b948a..e86c3e1 100644
--- a/libavcodec/h264_mp4toannexb_bsf.c
+++ b/libavcodec/h264_mp4toannexb_bsf.c
@@ -40,7 +40,7 @@ static int alloc_and_copy(uint8_t **poutbuf, int *poutbuf_size,
void *tmp;
*poutbuf_size += sps_pps_size + in_size + nal_header_size;
- tmp = av_realloc(*poutbuf, *poutbuf_size);
+ tmp = av_realloc(*poutbuf, *poutbuf_size + FF_INPUT_BUFFER_PADDING_SIZE);
if (!tmp)
return AVERROR(ENOMEM);
*poutbuf = tmp;
OpenPOWER on IntegriCloud