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 2003/05/13 22:31:32 UTC

cvs commit: cocoon-2.1/src/java/org/apache/cocoon/components/treeprocessor/sitemap RedirectToNodeBuilder.java

sylvain     2003/05/13 13:31:32

  Modified:    src/java/org/apache/cocoon/components/treeprocessor/sitemap
                        RedirectToNodeBuilder.java
  Log:
  Forbidding again redirects in handle-errors
  
  Revision  Changes    Path
  1.4       +6 -1      cocoon-2.1/src/java/org/apache/cocoon/components/treeprocessor/sitemap/RedirectToNodeBuilder.java
  
  Index: RedirectToNodeBuilder.java
  ===================================================================
  RCS file: /home/cvs/cocoon-2.1/src/java/org/apache/cocoon/components/treeprocessor/sitemap/RedirectToNodeBuilder.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- RedirectToNodeBuilder.java	29 Apr 2003 08:25:19 -0000	1.3
  +++ RedirectToNodeBuilder.java	13 May 2003 20:31:31 -0000	1.4
  @@ -81,6 +81,11 @@
   
       public ProcessingNode buildNode(Configuration config) throws Exception {
           
  +		if (((SitemapLanguage)this.treeBuilder).isBuildingErrorHandler()) {
  +			throw new ConfigurationException("'map:redirect' is forbidden inside a 'map:handle-errors', at "
  +			+ config.getLocation());
  +		}
  +		
           // Is it a redirect to resource ?
           this.resourceName = config.getAttribute("resource", null);
           if (this.resourceName != null) {