You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by sy...@apache.org on 2002/03/15 11:51:11 UTC

cvs commit: xml-cocoon2/src/java/org/apache/cocoon/components/treeprocessor/sitemap MountNode.java

sylvain     02/03/15 02:51:11

  Modified:    src/java/org/apache/cocoon/components/treeprocessor/sitemap
                        MountNode.java
  Log:
  Corrected mount : directory mounts (i.e. ending by "/") were reloaded at each request.
  Reported by volker.schmitt@basf-it-services.com
  
  Revision  Changes    Path
  1.2       +8 -3      xml-cocoon2/src/java/org/apache/cocoon/components/treeprocessor/sitemap/MountNode.java
  
  Index: MountNode.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/java/org/apache/cocoon/components/treeprocessor/sitemap/MountNode.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- MountNode.java	5 Mar 2002 08:26:23 -0000	1.1
  +++ MountNode.java	15 Mar 2002 10:51:11 -0000	1.2
  @@ -70,7 +70,7 @@
   /**
    *
    * @author <a href="mailto:sylvain@apache.org">Sylvain Wallez</a>
  - * @version CVS $Id: MountNode.java,v 1.1 2002/03/05 08:26:23 sylvain Exp $
  + * @version CVS $Id: MountNode.java,v 1.2 2002/03/15 10:51:11 sylvain Exp $
    */
   
   public class MountNode extends AbstractProcessingNode implements Composable {
  @@ -146,13 +146,18 @@
   
           if (processor == null) {
               
  +            // Handle directory mounts
  +            String actualSource;
               if (source.charAt(source.length() - 1) == '/') {
  -                source = source + "sitemap.xmap";
  +                actualSource = source + "sitemap.xmap";
  +            } else {
  +                actualSource = source;
               }
   
               processor = this.parentProcessor.createChildProcessor(
  -                this.manager, this.language, env.resolve(source));
  +                this.manager, this.language, env.resolve(actualSource));
   
  +            // Associate to the original source
               processors.put(source, processor);
           }
   
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          cocoon-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-cvs-help@xml.apache.org