You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Regis Xu (JIRA)" <ji...@apache.org> on 2008/08/28 06:22:46 UTC

[jira] Created: (HARMONY-5961) [classlib][luni]File.toURI() returns incorrect UNC uri

[classlib][luni]File.toURI() returns incorrect UNC uri
------------------------------------------------------

                 Key: HARMONY-5961
                 URL: https://issues.apache.org/jira/browse/HARMONY-5961
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
    Affects Versions: 5.0M7
            Reporter: Regis Xu
             Fix For: 5.0M8


below test case can pass on RI but failed on Harmony

    public void test_toURI_UNC() throws Exception {
        File f = new File("\\\\unchost\\[dir]\\file.txt");
        assertNotNull(f.toURI());
        assertTrue("incorrect URI for UNC path: " + f.toURI(), f.toURI().equals(new URI("file:////unchost/%5Bdir%5D/file.txt")));
    }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (HARMONY-5961) [classlib][luni]File.toURI() returns incorrect UNC uri

Posted by "Regis Xu (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-5961?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Regis Xu updated HARMONY-5961:
------------------------------

    Attachment: HARMONY-5961.diff

The patch only fix on windows. I notice Harmony has different behavior with RI when path name contains "\\"
Harmony convert it to "/" and treat it as path seperator, while RI doesn't do that.

> [classlib][luni]File.toURI() returns incorrect UNC uri
> ------------------------------------------------------
>
>                 Key: HARMONY-5961
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5961
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M7
>            Reporter: Regis Xu
>             Fix For: 5.0M8
>
>         Attachments: HARMONY-5961.diff
>
>
> below test case can pass on RI but failed on Harmony
>     public void test_toURI_UNC() throws Exception {
>         File f = new File("\\\\unchost\\[dir]\\file.txt");
>         assertNotNull(f.toURI());
>         assertTrue("incorrect URI for UNC path: " + f.toURI(), f.toURI().equals(new URI("file:////unchost/%5Bdir%5D/file.txt")));
>     }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (HARMONY-5961) [classlib][luni]File.toURI() returns incorrect UNC uri

Posted by "Sean Qiu (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-5961?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sean Qiu reassigned HARMONY-5961:
---------------------------------

    Assignee: Sean Qiu

> [classlib][luni]File.toURI() returns incorrect UNC uri
> ------------------------------------------------------
>
>                 Key: HARMONY-5961
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5961
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M7
>            Reporter: Regis Xu
>            Assignee: Sean Qiu
>             Fix For: 5.0M8
>
>         Attachments: HARMONY-5961.diff
>
>
> below test case can pass on RI but failed on Harmony
>     public void test_toURI_UNC() throws Exception {
>         File f = new File("\\\\unchost\\[dir]\\file.txt");
>         assertNotNull(f.toURI());
>         assertTrue("incorrect URI for UNC path: " + f.toURI(), f.toURI().equals(new URI("file:////unchost/%5Bdir%5D/file.txt")));
>     }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (HARMONY-5961) [classlib][luni]File.toURI() returns incorrect UNC uri

Posted by "Regis Xu (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-5961?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Regis Xu closed HARMONY-5961.
-----------------------------


Verified. Thanks Sean!

> [classlib][luni]File.toURI() returns incorrect UNC uri
> ------------------------------------------------------
>
>                 Key: HARMONY-5961
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5961
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M7
>            Reporter: Regis Xu
>            Assignee: Sean Qiu
>             Fix For: 5.0M8
>
>         Attachments: HARMONY-5961.diff
>
>
> below test case can pass on RI but failed on Harmony
>     public void test_toURI_UNC() throws Exception {
>         File f = new File("\\\\unchost\\[dir]\\file.txt");
>         assertNotNull(f.toURI());
>         assertTrue("incorrect URI for UNC path: " + f.toURI(), f.toURI().equals(new URI("file:////unchost/%5Bdir%5D/file.txt")));
>     }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (HARMONY-5961) [classlib][luni]File.toURI() returns incorrect UNC uri

Posted by "Sean Qiu (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-5961?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sean Qiu resolved HARMONY-5961.
-------------------------------

    Resolution: Fixed

Patch applied at r691095 with minor modification.
Please verify if it works as you expected.
Thank you.

> [classlib][luni]File.toURI() returns incorrect UNC uri
> ------------------------------------------------------
>
>                 Key: HARMONY-5961
>                 URL: https://issues.apache.org/jira/browse/HARMONY-5961
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M7
>            Reporter: Regis Xu
>            Assignee: Sean Qiu
>             Fix For: 5.0M8
>
>         Attachments: HARMONY-5961.diff
>
>
> below test case can pass on RI but failed on Harmony
>     public void test_toURI_UNC() throws Exception {
>         File f = new File("\\\\unchost\\[dir]\\file.txt");
>         assertNotNull(f.toURI());
>         assertTrue("incorrect URI for UNC path: " + f.toURI(), f.toURI().equals(new URI("file:////unchost/%5Bdir%5D/file.txt")));
>     }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.