[SCM] libav/experimental: Increase the SDP buffer size (again!) and also increase the temporary buffer size of the fmtp parameter buffer. For Vorbis RT(S)P, these contain full Vorbis headers, which can be up to 12kb each, formatted in base64, so 16kb total. Patch required for proper Vorbis/RTP playback, submitted as GSoC qualification task in the thread "RTP/Vorbis payload implementation (GSoC qual task)" by Colin McQuillan m.niloc googlemail com.

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 30 16:44:07 UTC 2013


The following commit has been merged in the experimental branch:
commit 373afbaf76eb315729b5b86fa4f3c70b10105c64
Author: Ronald S. Bultje <rsbultje at gmail.com>
Date:   Tue Apr 14 13:22:40 2009 +0000

    Increase the SDP buffer size (again!) and also increase the temporary
    buffer size of the fmtp parameter buffer. For Vorbis RT(S)P, these
    contain full Vorbis headers, which can be up to 12kb each, formatted
    in base64, so 16kb total. Patch required for proper Vorbis/RTP playback,
    submitted as GSoC qualification task in the thread "RTP/Vorbis payload
    implementation (GSoC qual task)" by Colin McQuillan m.niloc googlemail
    com.
    
    Originally committed as revision 18508 to svn://svn.ffmpeg.org/ffmpeg/trunk

diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 758314f..bb78def 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -261,7 +261,9 @@ int rtsp_next_attr_and_value(const char **p, char *attr, int attr_size, char *va
 static void sdp_parse_fmtp(AVStream *st, const char *p)
 {
     char attr[256];
-    char value[4096];
+    /* Vorbis setup headers can be up to 12KB and are sent base64
+     * encoded, giving a 12KB * (4/3) = 16KB FMTP line. */
+    char value[16384];
     int i;
 
     RTSPStream *rtsp_st = st->priv_data;
@@ -512,8 +514,10 @@ static int sdp_parse(AVFormatContext *s, const char *content)
      * contain long SDP lines containing complete ASF Headers (several
      * kB) or arrays of MDPR (RM stream descriptor) headers plus
      * "rulebooks" describing their properties. Therefore, the SDP line
-     * buffer is large. */
-    char buf[8192], *q;
+     * buffer is large.
+     *
+     * The Vorbis FMTP line can be up to 16KB - see sdp_parse_fmtp. */
+    char buf[16384], *q;
     SDPParseState sdp_parse_state, *s1 = &sdp_parse_state;
 
     memset(s1, 0, sizeof(SDPParseState));

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list