Commit ec5a6204 authored by rtogni's avatar rtogni

Check for memory allocation failure of temp buffer


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@11053 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent f532e5ff
......@@ -495,7 +495,8 @@ static int rm_assemble_video_frame(AVFormatContext *s, RMContext *rm, AVPacket *
if((seq & 0x7F) == 1 || rm->curpic_num != pic_num){
rm->slices = ((hdr & 0x3F) << 1) + 1;
ssize = len2 + 8*rm->slices + 1;
rm->videobuf = av_realloc(rm->videobuf, ssize);
if(!(rm->videobuf = av_realloc(rm->videobuf, ssize)))
return AVERROR(ENOMEM);
rm->videobufsize = ssize;
rm->videobufpos = 8*rm->slices + 1;
rm->cur_slice = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment