aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/h264.c
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2009-04-12 13:17:37 +0000
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2009-04-12 13:17:37 +0000
commit238ef6dadd13b9a867eaa7382bdba751e25c40b9 (patch)
treeac0228289581351403ee3f1d9ad187919d498fbb /libavcodec/h264.c
parent9bf993a5b5f8bf10c590d83c795467606f92cf6e (diff)
downloadffmpeg-238ef6dadd13b9a867eaa7382bdba751e25c40b9.tar.gz
Add a av_fast_malloc function and replace several uses of av_fast_realloc,
thus avoiding potential memleaks and pointless memcpys. Originally committed as revision 18470 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r--libavcodec/h264.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index b3c01a9ffb..ff6ff567bd 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -1411,7 +1411,7 @@ const uint8_t *ff_h264_decode_nal(H264Context *h, const uint8_t *src, int *dst_l
}
bufidx = h->nal_unit_type == NAL_DPC ? 1 : 0; // use second escape buffer for inter data
- h->rbsp_buffer[bufidx]= av_fast_realloc(h->rbsp_buffer[bufidx], &h->rbsp_buffer_size[bufidx], length+FF_INPUT_BUFFER_PADDING_SIZE);
+ av_fast_malloc(&h->rbsp_buffer[bufidx], &h->rbsp_buffer_size[bufidx], length+FF_INPUT_BUFFER_PADDING_SIZE);
dst= h->rbsp_buffer[bufidx];
if (dst == NULL){