You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@struts.apache.org by ba...@apache.org on 2007/04/16 22:19:18 UTC
svn commit: r529384 -
/struts/struts1/branches/STRUTS_1_3_BRANCH/tiles/src/main/java/org/apache/struts/tiles/TilesUtilImpl.java
Author: bayard
Date: Mon Apr 16 13:19:17 2007
New Revision: 529384
URL: http://svn.apache.org/viewvc?view=rev&rev=529384
Log:
Applying patch from STR-3021. Thanks to Thomas Wilhelm for reporting the bug wherein exceptions thrown in tiles-included JSPs cause includes to happen twice. The change was to not consider an InvocationTargetException as a debug item, but as an exception whose contents need to be rethrown.
Modified:
struts/struts1/branches/STRUTS_1_3_BRANCH/tiles/src/main/java/org/apache/struts/tiles/TilesUtilImpl.java
Modified: struts/struts1/branches/STRUTS_1_3_BRANCH/tiles/src/main/java/org/apache/struts/tiles/TilesUtilImpl.java
URL: http://svn.apache.org/viewvc/struts/struts1/branches/STRUTS_1_3_BRANCH/tiles/src/main/java/org/apache/struts/tiles/TilesUtilImpl.java?view=diff&rev=529384&r1=529383&r2=529384
==============================================================================
--- struts/struts1/branches/STRUTS_1_3_BRANCH/tiles/src/main/java/org/apache/struts/tiles/TilesUtilImpl.java (original)
+++ struts/struts1/branches/STRUTS_1_3_BRANCH/tiles/src/main/java/org/apache/struts/tiles/TilesUtilImpl.java Mon Apr 16 13:19:17 2007
@@ -132,7 +132,13 @@
} catch (IllegalAccessException e) {
log.debug("Could not find JSP 2.0 include method. Using old one.", e);
} catch (InvocationTargetException e) {
- log.debug("Unable to execute JSP 2.0 include method. Trying old one.", e);
+ if (e.getCause() instanceof ServletException){
+ throw ((ServletException)e.getCause());
+ } else if (e.getCause() instanceof IOException){
+ throw ((IOException)e.getCause());
+ } else {
+ throw new ServletException(e);
+ }
}
pageContext.include(uri);