OSDN Git Service

Don't forget to set known audio parameters (samplerate, etc.) if the codec is
authorRonald S. Bultje <rsbultje@gmail.com>
Wed, 10 Feb 2010 18:30:55 +0000 (18:30 +0000)
committerRonald S. Bultje <rsbultje@gmail.com>
Wed, 10 Feb 2010 18:30:55 +0000 (18:30 +0000)
not supported in FFmpeg. This will cause crashes later because the samplerate
is used to initialize the timebase.

Originally committed as revision 21741 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavformat/rtsp.c

index d1738dd..171d707 100644 (file)
@@ -131,9 +131,8 @@ static int sdp_parse_rtpmap(AVFormatContext *s,
     if (c && c->name)
         c_name = c->name;
     else
-        c_name = (char *) NULL;
+        c_name = "(null)";
 
-    if (c_name) {
         get_word_sep(buf, sizeof(buf), "/", &p);
         i = atoi(buf);
         switch (codec->codec_type) {
@@ -164,9 +163,6 @@ static int sdp_parse_rtpmap(AVFormatContext *s,
             break;
         }
         return 0;
-    }
-
-    return -1;
 }
 
 /* return the length and optionally the data */