You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Don Brown (JIRA)" <ji...@apache.org> on 2006/11/17 08:47:00 UTC

[jira] Closed: (WW-559) Memory Leak in ComponentTag (patch included)

     [ http://issues.apache.org/struts/browse/WW-559?page=all ]

Don Brown closed WW-559.
------------------------

    Resolution: Not A Problem

> Memory Leak in ComponentTag (patch included)
> --------------------------------------------
>
>                 Key: WW-559
>                 URL: http://issues.apache.org/struts/browse/WW-559
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Views
>    Affects Versions: WW 1.4.1
>         Environment: ---
>            Reporter: Paolo Vedovato
>
> As found in Feb. 2004 in cooperation with Dick Zetterberg I include the relevant code snipplet for the ComponentTag.java memory leak fix as a reminder to include for the coming release.
> this fixes the problem:
>       // Put params on the stack
>       addParameterInternal("label", findValue(labelAttr));
>       
>       Object value = null;
> //>>> look for the nameAttr only if we have one
>       if ( nameAttr != null )
>       {
>          value = findValue(nameAttr);
>          if (value != null) {
>             addParameterInternal("name", value);
>          }
>       }
>       // If value attribute is not given, use the name
> //>>> call addParametrInternal if it makes sense
>       if (valueAttr == null) {
>          if ( value != null ){
>             addParameterInternal("nameValue",
> findValue(BeanUtil.toStringValue(value)));
>          }
>       } else {
>          if (log.isDebugEnabled()) {
>             log.debug("valueAttr:" + valueAttr);
>             log.debug("Setting value to:" + findValue(valueAttr));
>          }
>          addParameterInternal("nameValue", findValue(valueAttr));
>       }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/struts/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira