You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@struts.apache.org by ap...@apache.org on 2006/12/13 14:09:03 UTC
svn commit: r486634 -
/struts/struts1/trunk/tiles2/src/main/java/org/apache/struts/tiles2/commands/TilesPreProcessor.java
Author: apetrelli
Date: Wed Dec 13 05:09:02 2006
New Revision: 486634
URL: http://svn.apache.org/viewvc?view=rev&rev=486634
Log:
STR-2986
Corrected TilesPreProcessor: the return value must be decided before rendering the definition.
Modified:
struts/struts1/trunk/tiles2/src/main/java/org/apache/struts/tiles2/commands/TilesPreProcessor.java
Modified: struts/struts1/trunk/tiles2/src/main/java/org/apache/struts/tiles2/commands/TilesPreProcessor.java
URL: http://svn.apache.org/viewvc/struts/struts1/trunk/tiles2/src/main/java/org/apache/struts/tiles2/commands/TilesPreProcessor.java?view=diff&rev=486634&r1=486633&r2=486634
==============================================================================
--- struts/struts1/trunk/tiles2/src/main/java/org/apache/struts/tiles2/commands/TilesPreProcessor.java (original)
+++ struts/struts1/trunk/tiles2/src/main/java/org/apache/struts/tiles2/commands/TilesPreProcessor.java Wed Dec 13 05:09:02 2006
@@ -89,6 +89,7 @@
ForwardConfig forwardConfig = sacontext.getForwardConfig();
if (forwardConfig == null || forwardConfig.getPath() == null)
{
+ // this is not a serious error, so log at low priority
log.debug("No forwardConfig or no path, so pass to next command.");
return (false);
}
@@ -101,9 +102,11 @@
return false;
}
+ boolean retValue = false;
+
if (container.isValidDefinition(sacontext.getRequest(),
sacontext.getResponse(), forwardConfig.getPath())) {
- // this is not a serious error, so log at low priority
+ retValue = sacontext.getResponse().isCommitted();
container.render(sacontext.getRequest(), sacontext.getResponse(),
forwardConfig.getPath());
} else {
@@ -114,6 +117,6 @@
}
}
- return sacontext.getResponse().isCommitted();
+ return retValue;
}
}