[FFmpeg-devel] [PATCH] url_split() ipv6 support

Michael Niedermayer michaelni
Sat Sep 29 01:12:48 CEST 2007


Hi

On Fri, Sep 28, 2007 at 04:21:41PM -0400, Ronald S. Bultje wrote:
> Hi,
> 
> On 9/28/07, Michael Niedermayer <michaelni at gmx.at> wrote:
> >
> > i want the correct official notations supported
> > that said rfc2732 and rfc3986 say [ipv6]
> > and rfc4291 has no match for URI, URL or resource so i do not think that
> > the other notations are defined in the context of URLs
> 
> 
> OK, attached patch does only support [] then.
> 
> Just for reference:
> 
> $ ./test-url_split "test.avi"-> "" :// "" @ "" : "-1" / "test.avi"
> "/tmp/test.mp3"-> "" :// "" @ "" : "-1" / "/tmp/test.mp3"
> "file:///tmp/test.mp3"-> "file" :// "" @ "" : "-1" / "/tmp/test.mp3"
> "http://www.address.com"-> "http" :// "" @ "www.address.com" : "-1" / ""
> "http://www.address.com/"-> "http" :// "" @ "www.address.com" : "-1" / "/"
> "http://www.address.com:80"-> "http" :// "" @ "www.address.com" : "80" / ""
> "http://www.address.com:80/"-> "http" :// "" @ "www.address.com" : "80" /
> "/"
> "http://www.address.com:80/test.mp3"-> "http" :// "" @ "www.address.com" :
> "80" / "/test.mp3"
> "http://1.2.3.4:80/test.mp4"-> "http" :// "" @ "1.2.3.4" : "80" /
> "/test.mp4"
> * "http://:1::80:1/test.mov"-> "http" :// "" @ "" : "1" / "/test.mov"
> * "http://:::80/test.mp5"-> "http" :// "" @ "" : "0" / "/test.mp5"
> "http://[::1]:80/test.mp6"-> "http" :// "" @ "::1" : "80" / "/test.mp6"
> "http://[host.address]:80/test.mp3"-> "http" :// "" @ "host.address" : "80"
> / "/test.mp3"
> "file:///[pat]h/to/file.mp3"-> "file" :// "" @ "" : "-1" /
> "/[pat]h/to/file.mp3"
> * "http://1:2:3:4:5:6:7:8:80/test.mp3"-> "http" :// "" @ "1" : "2" /
> "/test.mp3"
> "http://me@:::80/test.mp3"-> "http" :// "me" @ "" : "0" / "/test.mp3"
> "http://me:x@:::80/test.mp3"-> "http" :// "me:x" @ "" : "0" / "/test.mp3"
> 
> The three marked with * fail and that's OK in this case.

patch looks ok

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

No great genius has ever existed without some touch of madness. -- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070929/d35145d9/attachment.pgp>



More information about the ffmpeg-devel mailing list