[FFmpeg-cvslog] ffprobe: check av_frame_alloc() failure.
Nicolas George
git at videolan.org
Tue Jan 7 21:35:32 CET 2014
ffmpeg | branch: release/2.1 | Nicolas George <george at nsup.org> | Sun Dec 29 10:37:58 2013 +0100| [a6ba0f7be91fcb4738d226b3b100a4750baf4340] | committer: Michael Niedermayer
ffprobe: check av_frame_alloc() failure.
(cherry picked from commit a55692a96099c40aabb25e1443890be99f9c845c)
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a6ba0f7be91fcb4738d226b3b100a4750baf4340
---
ffprobe.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/ffprobe.c b/ffprobe.c
index d07a58b..a7aef02 100644
--- a/ffprobe.c
+++ b/ffprobe.c
@@ -1668,6 +1668,10 @@ static int read_interval_packets(WriterContext *w, AVFormatContext *fmt_ctx,
}
frame = av_frame_alloc();
+ if (!frame) {
+ ret = AVERROR(ENOMEM);
+ goto end;
+ }
while (!av_read_frame(fmt_ctx, &pkt)) {
if (selected_streams[pkt.stream_index]) {
AVRational tb = fmt_ctx->streams[pkt.stream_index]->time_base;
More information about the ffmpeg-cvslog
mailing list