commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jeri...@apache.org
Subject cvs commit: jakarta-commons/httpclient/src/java/org/apache/commons/httpclient URI.java
Date Sun, 22 Sep 2002 19:21:59 GMT
jericho     2002/09/22 12:21:59

  Modified:    httpclient/src/java/org/apache/commons/httpclient URI.java
  Log:
  - Fix a wrong computation for the getRawName method.
  
  Revision  Changes    Path
  1.2       +6 -6      jakarta-commons/httpclient/src/java/org/apache/commons/httpclient/URI.java
  
  Index: URI.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/httpclient/src/java/org/apache/commons/httpclient/URI.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- URI.java	22 Sep 2002 05:19:50 -0000	1.1
  +++ URI.java	22 Sep 2002 19:21:59 -0000	1.2
  @@ -2622,15 +2622,15 @@
           if (_path == null) return null;
   
           int at = 0;
  -        for (int i = _path.length - 1; i >= 0 ; i--) {
  +        for (int i = _path.length - 1; i >= 0; i--) {
               if (_path[i] == '/') {
  -                at = i;
  +                at = i + 1;
                   break;
               }
           }
           int len = _path.length - at;
           char[] basename =  new char[len];
  -        System.arraycopy(_path, at + 1, basename, 0, len);
  +        System.arraycopy(_path, at, basename, 0, len);
           return basename;
       }
   
  
  
  

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message