diff options
author | Michael Niedermayer | 2014-12-15 23:26:54 +0100 |
---|---|---|
committer | Michael Niedermayer | 2014-12-15 23:26:54 +0100 |
commit | d2f9aefbde5bebac1af9eb6f3c41250fb8d5c0c0 (patch) | |
tree | 3ca81d8414e2cde6ceff6b3b2f5e6145a8575688 /ffmpeg.c | |
parent | 4f1923a91b8c2e0ec034f60083df983b6d19fe44 (diff) |
ffmpeg: Check for subtitle_out malloc failure
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'ffmpeg.c')
-rw-r--r-- | ffmpeg.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -819,6 +819,10 @@ static void do_subtitle_out(AVFormatContext *s, if (!subtitle_out) { subtitle_out = av_malloc(subtitle_out_max_size); + if (!subtitle_out) { + av_log(NULL, AV_LOG_FATAL, "Failed to allocate subtitle_out\n"); + exit_program(1); + } } /* Note: DVB subtitle need one packet to draw them and one other |