https://bz.apache.org/bugzilla/show_bug.cgi?id=69285

John Engebretson <jeng...@amazon.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|FIXED                       |---
             Status|RESOLVED                    |REOPENED

--- Comment #5 from John Engebretson <jeng...@amazon.com> ---
This code reached production and was ineffective; investigation shows that the
caller (ApplicationHttpRequest.parseParameters) is still calling the old
constructor, based on Map rather than ParameterMap.  Specifically:

parameters = new ParameterMap<>(getRequest().getParameterMap());

At compile time, this resolves to calling ParameterMap.<init>(Map).  The new
constructor must be accessed by casting the parameter, such as this:

parameters = new
ParameterMap<>((ParameterMap)(getRequest().getParameterMap()));

Sorry, my development environment contained this change as well as the code I
included previously, and I lost track of it.

Curious what you think about whether we need to typecheck this before casting;
it appears that all calls to getRequest().getParameterMap() will return a
ParameterMap, but with some effort an application could override that.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to