From 3b05f1293347de666f4c4ab57496bae0564ed9d2 Mon Sep 17 00:00:00 2001 From: remm Date: Thu, 20 Apr 2006 12:46:25 +0000 Subject: [PATCH] - Fix improper caching by checking the class definition. git-svn-id: https://svn.apache.org/repos/asf/tomcat/tc6.0.x/trunk@395575 13f79535-47bb-0310-9956-ffa450edef68 --- java/javax/el/BeanELResolver.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/java/javax/el/BeanELResolver.java b/java/javax/el/BeanELResolver.java index b947083b5..7a05331de 100644 --- a/java/javax/el/BeanELResolver.java +++ b/java/javax/el/BeanELResolver.java @@ -194,6 +194,10 @@ public class BeanELResolver extends ELResolver { } return property; } + + public Class getType() { + return type; + } } private final static class BeanProperty { @@ -253,7 +257,7 @@ public class BeanELResolver extends ELResolver { String prop = property.toString(); BeanProperties props = this.cache.get(type.getName()); - if (props == null) { + if (props == null || type != props.getType()) { props = new BeanProperties(type); this.cache.put(type.getName(), props); } -- 2.11.0