From 0307cc2253e76772b1c645ac6117d08da87a147c Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sat, 5 Jul 2014 07:01:07 +0000 Subject: rtpdec: pass an AVFormatContext to ff_parse_fmtp() Use it for logging, instead of NULL or the stream codec context. --- libavformat/rtpdec_ilbc.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'libavformat/rtpdec_ilbc.c') diff --git a/libavformat/rtpdec_ilbc.c b/libavformat/rtpdec_ilbc.c index 2e99734f2a..bff47c7ac2 100644 --- a/libavformat/rtpdec_ilbc.c +++ b/libavformat/rtpdec_ilbc.c @@ -23,7 +23,8 @@ #include "rtpdec_formats.h" #include "libavutil/avstring.h" -static int ilbc_parse_fmtp(AVStream *stream, PayloadContext *data, +static int ilbc_parse_fmtp(AVFormatContext *s, + AVStream *stream, PayloadContext *data, char *attr, char *value) { if (!strcmp(attr, "mode")) { @@ -36,7 +37,7 @@ static int ilbc_parse_fmtp(AVStream *stream, PayloadContext *data, stream->codec->block_align = 50; break; default: - av_log(NULL, AV_LOG_ERROR, "Unsupported iLBC mode %d\n", mode); + av_log(s, AV_LOG_ERROR, "Unsupported iLBC mode %d\n", mode); return AVERROR(EINVAL); } } @@ -54,7 +55,7 @@ static int ilbc_parse_sdp_line(AVFormatContext *s, int st_index, st = s->streams[st_index]; if (av_strstart(line, "fmtp:", &p)) { - int ret = ff_parse_fmtp(st, data, p, ilbc_parse_fmtp); + int ret = ff_parse_fmtp(s, st, data, p, ilbc_parse_fmtp); if (ret < 0) return ret; if (!st->codec->block_align) { -- cgit v1.2.3