ffmpeg | branch: master | Michael Lynch <mtly...@google.com> | Tue Oct 14 16:30:39 2014 -0400| [c69f230a3afbfa30d7a978a6961b1ddcc774499f] | committer: Michael Niedermayer
avformat/rtsp: check memory allocation Reviewed-by: Reimar Döffinger <reimar.doeffin...@gmx.de> Commit message by: Benoit Fouet <benoit.fo...@free.fr> Signed-off-by: Michael Niedermayer <michae...@gmx.at> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c69f230a3afbfa30d7a978a6961b1ddcc774499f --- libavformat/rtsp.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c index 523a7c0..77f03ba 100644 --- a/libavformat/rtsp.c +++ b/libavformat/rtsp.c @@ -1150,6 +1150,8 @@ start: if (content_length > 0) { /* leave some room for a trailing '\0' (useful for simple parsing) */ content = av_malloc(content_length + 1); + if (!content) + return AVERROR(ENOMEM); ffurl_read_complete(rt->rtsp_hd, content, content_length); content[content_length] = '\0'; } _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog