Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mpc-hc/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-01-17 03:40:39 +0300
committerMichael Niedermayer <michaelni@gmx.at>2015-01-17 03:40:39 +0300
commit040e5703e6b8d1d10e389ee5ecd91711c61b8378 (patch)
tree37a298c14f27e18a245d0b91bd1ec138386f89df /libavcodec
parentf96148913b310c16302eb9a50f480d6e46fc04e5 (diff)
avcodec/flac_parser: print error messages in case of errors
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/flac_parser.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/libavcodec/flac_parser.c b/libavcodec/flac_parser.c
index d16af29efd..ed0da55c23 100644
--- a/libavcodec/flac_parser.c
+++ b/libavcodec/flac_parser.c
@@ -194,6 +194,8 @@ static int find_headers_search_validate(FLACParseContext *fpc, int offset)
FLAC_MAX_SEQUENTIAL_HEADERS);
if (!(*end_handle)->link_penalty) {
av_freep(end_handle);
+ av_log(fpc->avctx, AV_LOG_ERROR,
+ "couldn't allocate link_penalty\n");
return AVERROR(ENOMEM);
}
@@ -712,8 +714,11 @@ static av_cold int flac_parse_init(AVCodecParserContext *c)
/* There will generally be FLAC_MIN_HEADERS buffered in the fifo before
it drains. This is allocated early to avoid slow reallocation. */
fpc->fifo_buf = av_fifo_alloc_array(FLAC_MIN_HEADERS + 3, FLAC_AVG_FRAME_SIZE);
- if (!fpc->fifo_buf)
+ if (!fpc->fifo_buf) {
+ av_log(fpc->avctx, AV_LOG_ERROR,
+ "couldn't allocate fifo_buf\n");
return AVERROR(ENOMEM);
+ }
return 0;
}