[FFmpeg-cvslog] avformat/sdp: add missing FF_API_LAVF_AVCTX check

James Almer git at videolan.org
Fri Oct 2 06:36:24 EEST 2020


ffmpeg | branch: master | James Almer <jamrial at gmail.com> | Thu Oct  1 22:45:34 2020 -0300| [10c01c3779414098a875b5908dfd5d79813f1a91] | committer: James Almer

avformat/sdp: add missing FF_API_LAVF_AVCTX check

Signed-off-by: James Almer <jamrial at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=10c01c3779414098a875b5908dfd5d79813f1a91
---

 libavformat/sdp.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/libavformat/sdp.c b/libavformat/sdp.c
index 2ce1a62262..95f3fbb876 100644
--- a/libavformat/sdp.c
+++ b/libavformat/sdp.c
@@ -704,6 +704,8 @@ static char *sdp_write_media_attributes(char *buff, int size, AVStream *st, int
         case AV_CODEC_ID_SPEEX:
             av_strlcatf(buff, size, "a=rtpmap:%d speex/%d\r\n",
                                      payload_type, p->sample_rate);
+#if FF_API_LAVF_AVCTX
+FF_DISABLE_DEPRECATION_WARNINGS
             if (st->codec) {
                 const char *mode;
                 uint64_t vad_option;
@@ -718,6 +720,8 @@ static char *sdp_write_media_attributes(char *buff, int size, AVStream *st, int
                 av_strlcatf(buff, size, "a=fmtp:%d vbr=%s\r\n",
                                         payload_type, mode);
             }
+FF_ENABLE_DEPRECATION_WARNINGS
+#endif
             break;
         case AV_CODEC_ID_OPUS:
             /* The opus RTP draft says that all opus streams MUST be declared



More information about the ffmpeg-cvslog mailing list