OSDN Git Service

Parse options in the RTSP URL only from the last question mark onwards
authorMartin Storsjö <martin@martin.st>
Tue, 23 Mar 2010 07:59:23 +0000 (07:59 +0000)
committerMartin Storsjö <martin@martin.st>
Tue, 23 Mar 2010 07:59:23 +0000 (07:59 +0000)
This helps if the URL (erroneously?) contains question marks within the path.

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

libavformat/rtsp.c

index 5a751f4..63103d0 100644 (file)
@@ -1449,7 +1449,7 @@ redirect:
         port = RTSP_DEFAULT_PORT;
 
     /* search for options */
-    option_list = strchr(path, '?');
+    option_list = strrchr(path, '?');
     if (option_list) {
         /* Strip out the RTSP specific options, write out the rest of
          * the options back into the same string. */