You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2022/02/15 16:47:32 UTC

[tomcat] branch 8.5.x updated: Fix ELContext save/restore after fragment helper invoke

This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git


The following commit(s) were added to refs/heads/8.5.x by this push:
     new 4044d19  Fix ELContext save/restore after fragment helper invoke
4044d19 is described below

commit 4044d196be70b23ef1143ebc7ad951541a611830
Author: Dmitri Blinov <dm...@mail.ru>
AuthorDate: Sun Feb 13 15:07:15 2022 +0300

    Fix ELContext save/restore after fragment helper invoke
---
 java/org/apache/jasper/runtime/JspContextWrapper.java | 4 +++-
 webapps/docs/changelog.xml                            | 8 ++++++++
 2 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/java/org/apache/jasper/runtime/JspContextWrapper.java b/java/org/apache/jasper/runtime/JspContextWrapper.java
index ccccd35..6548d38 100644
--- a/java/org/apache/jasper/runtime/JspContextWrapper.java
+++ b/java/org/apache/jasper/runtime/JspContextWrapper.java
@@ -555,7 +555,9 @@ public class JspContextWrapper extends PageContext implements VariableResolver {
 
         @Override
         public void putContext(@SuppressWarnings("rawtypes") Class key, Object contextObject) {
-            wrapped.putContext(key, contextObject);
+            if (key != JspContext.class) {
+                wrapped.putContext(key, contextObject);
+            }
         }
 
         @Override
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 157f436..b868781 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -172,6 +172,14 @@
       </fix>
     </changelog>
   </subsection>
+  <subsection name="Jasper">
+    <changelog>
+      <fix>
+        <pr>474</pr>: Prevent a tag file from corrupting the ELContext of the
+        calling page. Pull request provided by Dmitri Blinov. (markt)
+      </fix>
+    </changelog>
+  </subsection>
   <subsection name="Web applications">
     <changelog>
       <fix>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org