stephan     2003/01/11 12:19:54

  Modified:    .        changes.xml
               src/java/org/apache/cocoon/util IOUtils.java
  Log:
  Add patch 14700 from bugzilla, which also solves the failed
  IOUtils test case.
  
  Revision  Changes    Path
  1.335     +5 -1      xml-cocoon2/changes.xml
  
  Index: changes.xml
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/changes.xml,v
  retrieving revision 1.334
  retrieving revision 1.335
  diff -u -r1.334 -r1.335
  --- changes.xml       9 Jan 2003 18:20:19 -0000       1.334
  +++ changes.xml       11 Jan 2003 20:19:54 -0000      1.335
  @@ -40,6 +40,10 @@
    </devs>
   
    <release version="@version@" date="@date@">
  +  <action dev="SMS" type="update" due-to="Michael Enke" 
  +          due-to-email="[EMAIL PROTECTED]" fixes-bug="14700">
  +    Patch IOUtils to recognize '..' in Path
  +  </action>
     <action dev="SW" type="update">
       The "mime-type" attribute on &lt;map:read&gt; and &lt;map:serialize&gt; is now
       expanded if it contains sitemap variables.
  
  
  
  1.8       +10 -1     xml-cocoon2/src/java/org/apache/cocoon/util/IOUtils.java
  
  Index: IOUtils.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/util/IOUtils.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- IOUtils.java      29 Mar 2002 20:16:34 -0000      1.7
  +++ IOUtils.java      11 Jan 2003 20:19:54 -0000      1.8
  @@ -226,6 +226,15 @@
   
       StringBuffer buffer = new StringBuffer();
       for (int i = start; i < path.length; i++) {
  +
  +      if(path[i].equals("..")) {
  +        int lio = buffer.lastIndexOf(File.separator);
  +        if(lio != -1) {
  +          buffer.setLength(lio);
  +          continue;
  +        }
  +      }
  +
         if (i > start) {
           buffer.append(File.separator);
         }
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     [EMAIL PROTECTED]
To unsubscribe, e-mail:          [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to