[FFmpeg-cvslog] r21000 - in trunk: ffserver.c libavformat/utils.c

stefano subversion
Sat Jan 2 00:56:09 CET 2010


Author: stefano
Date: Sat Jan  2 00:56:09 2010
New Revision: 21000

Log:
Use av_match_ext() in place of the deprecated match_ext() function.

Modified:
   trunk/ffserver.c
   trunk/libavformat/utils.c

Modified: trunk/ffserver.c
==============================================================================
--- trunk/ffserver.c	Sat Jan  2 00:53:02 2010	(r20999)
+++ trunk/ffserver.c	Sat Jan  2 00:56:09 2010	(r21000)
@@ -1340,20 +1340,20 @@ static int http_parse_request(HTTPContex
     }
 
     redir_type = REDIR_NONE;
-    if (match_ext(filename, "asx")) {
+    if (av_match_ext(filename, "asx")) {
         redir_type = REDIR_ASX;
         filename[strlen(filename)-1] = 'f';
-    } else if (match_ext(filename, "asf") &&
+    } else if (av_match_ext(filename, "asf") &&
         (!useragent || strncasecmp(useragent, "NSPlayer", 8) != 0)) {
         /* if this isn't WMP or lookalike, return the redirector file */
         redir_type = REDIR_ASF;
-    } else if (match_ext(filename, "rpm,ram")) {
+    } else if (av_match_ext(filename, "rpm,ram")) {
         redir_type = REDIR_RAM;
         strcpy(filename + strlen(filename)-2, "m");
-    } else if (match_ext(filename, "rtsp")) {
+    } else if (av_match_ext(filename, "rtsp")) {
         redir_type = REDIR_RTSP;
         compute_real_filename(filename, sizeof(filename) - 1);
-    } else if (match_ext(filename, "sdp")) {
+    } else if (av_match_ext(filename, "sdp")) {
         redir_type = REDIR_SDP;
         compute_real_filename(filename, sizeof(filename) - 1);
     }

Modified: trunk/libavformat/utils.c
==============================================================================
--- trunk/libavformat/utils.c	Sat Jan  2 00:53:02 2010	(r20999)
+++ trunk/libavformat/utils.c	Sat Jan  2 00:56:09 2010	(r21000)
@@ -222,7 +222,7 @@ AVOutputFormat *av_guess_format(const ch
         if (fmt->mime_type && mime_type && !strcmp(fmt->mime_type, mime_type))
             score += 10;
         if (filename && fmt->extensions &&
-            match_ext(filename, fmt->extensions)) {
+            av_match_ext(filename, fmt->extensions)) {
             score += 5;
         }
         if (score > score_max) {
@@ -325,7 +325,7 @@ static AVInputFormat *av_probe_input_for
         if (fmt1->read_probe) {
             score = fmt1->read_probe(pd);
         } else if (fmt1->extensions) {
-            if (match_ext(pd->filename, fmt1->extensions)) {
+            if (av_match_ext(pd->filename, fmt1->extensions)) {
                 score = 50;
             }
         }



More information about the ffmpeg-cvslog mailing list