as3corelib
as3corelib copied to clipboard
URI.makeAbsoluteURI does not handle local windows filepaths properly
Originally filed by gae.local.test on 2010-07-12T05:40:26
_uri1 = new URI("example.txt"); _url2 = new URI("file://C:/path/to/aDifferentExample.txt"); _uri1.makeAbsoluteURI(_url2 ).toString() returns the string "file://c/path/toexample.txt"
expected output --> string "file://c:/path/to/toexample.txt" (notice the colon in c:/)
I copy and pasted trace output and then shortened for readability. The problem is that the method is removing the colon after the drive identifier.
I am using the current revision at revision 118 according to tortoise svn
Updated by gae.local.test on 2010-07-12T05:41:54
I made copy and paste errors. The only thing that is wrong with the string it prints out is the missing colon after the drive letter. I can't edit my post to fix it.
Please note that file://c:/path/to/toexample.txt is actually a broken URI. It should encode to file:///c:/path/to/toexample.txt which equates to file://localhost/c:/path/to/toexample.txt