hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Binglin Chang (JIRA)" <j...@apache.org>
Subject [jira] [Created] (HADOOP-9897) Add method to get path start position without drive specifier in o.a.h.fs.Path
Date Thu, 22 Aug 2013 16:20:55 GMT
Binglin Chang created HADOOP-9897:
-------------------------------------

             Summary: Add method to get path start position without drive specifier in o.a.h.fs.Path
 
                 Key: HADOOP-9897
                 URL: https://issues.apache.org/jira/browse/HADOOP-9897
             Project: Hadoop Common
          Issue Type: Improvement
            Reporter: Binglin Chang
            Assignee: Binglin Chang
            Priority: Trivial


There are a lot of code in Path to get start position after skipping drive specifier, like:

{code}
    int start = hasWindowsDrive(uri.getPath()) ? 3 : 0;
{code}

First, using hard coded 3 or 0 is bad, second, the code always assumes path is with "/" prefix.


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message