You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Vadim Gritsenko <va...@verizon.net> on 2002/02/10 05:42:21 UTC
CocoonComponentManager leaking
Carsten,
It seems to me that there is a memory leak in the
CocoonComponentManager. I went ahead and patched, please confirm that I
understood the logic correctly ;)
Patch:
if ( !stack.empty() ) {
final Object[] objects = (Object[])stack.peek();
if ( objects[1] == objectModel ) {
stack.push(new Object[] {resolver,
objectModel,
objects[2],
new
Integer(((Integer)objects[3]).intValue()+1)});
+ return;
}
}
stack.push(new Object[] {resolver, objectModel, new HashMap(5),
ONE});
Vadim
---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org
RE: CocoonComponentManager leaking
Posted by Carsten Ziegeler <cz...@s-und-n.de>.
> Vadim Gritsenko wrote:
>
> Carsten,
>
> It seems to me that there is a memory leak in the
> CocoonComponentManager. I went ahead and patched, please confirm that I
> understood the logic correctly ;)
>
> Patch:
> if ( !stack.empty() ) {
> final Object[] objects = (Object[])stack.peek();
> if ( objects[1] == objectModel ) {
> stack.push(new Object[] {resolver,
> objectModel,
> objects[2],
> new
> Integer(((Integer)objects[3]).intValue()+1)});
> + return;
> }
> }
> stack.push(new Object[] {resolver, objectModel, new HashMap(5),
> ONE});
>
>
Hi Vadim,
thanks for patching this. Your patch is 100% correct - I just forgot
the "return" statement.
Thanks,
Carsten
---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org