From 30eae325302a99fd6c3051c34b60a605765e026c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Martin=20Storsj=C3=B6?= Date: Sun, 2 Jan 2011 14:32:18 +0200 Subject: [PATCH] rtsp: Parse the x-Accept-Dynamic-Rate header MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Martin Storsjö --- libavformat/rtsp.c | 3 +++ libavformat/rtsp.h | 3 +++ 2 files changed, 6 insertions(+) diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c index ff4d16a..ba104d2 100644 --- a/libavformat/rtsp.c +++ b/libavformat/rtsp.c @@ -808,6 +808,9 @@ void ff_rtsp_parse_line(RTSPMessageHeader *reply, const char *buf, if (strstr(p, "GET_PARAMETER") && method && !strcmp(method, "OPTIONS")) rt->get_parameter_supported = 1; + } else if (av_stristart(p, "x-Accept-Dynamic-Rate:", &p) && rt) { + p += strspn(p, SPACE_CHARS); + rt->accept_dynamic_rate = atoi(p); } } diff --git a/libavformat/rtsp.h b/libavformat/rtsp.h index 265d9f8..62ca483 100644 --- a/libavformat/rtsp.h +++ b/libavformat/rtsp.h @@ -346,6 +346,9 @@ typedef struct RTSPState { * Option flags for the chained RTP muxer. */ int rtp_muxer_flags; + + /** Whether the server accepts the x-Dynamic-Rate header */ + int accept_dynamic_rate; } RTSPState; /** -- 2.7.4