Bug 21043

Summary: REGRESSION: Leak of AnimationLists (and whole RenderStyles?)
Product: WebKit Reporter: mitz
Component: CSSAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: dino, simon.fraser
Priority: P1 Keywords: LayoutTestFailure, Regression
Version: 528+ (Nightly build)   
Hardware: Macintosh   
OS: OS X 10.5   
URL: http://build.webkit.org/results/trunk-mac-intel-debug/5071/DumpRenderTree-leaks.txt
Bug Depends on: 20995    
Bug Blocks:    
Attachments:
Description Flags
Patch, changelog andersca: review+

Description mitz 2008-09-23 15:38:48 PDT
The leaks bot is showing many leaks beneath accessAnimations(). See URL.
Comment 1 Simon Fraser (smfr) 2008-09-23 18:19:05 PDT
I don't see any leaks when I run the animation tests:
wktests --debug --leaks LayoutTests/animations/
animations ..............
 ? checking for leaks in DumpRenderTree
 - no leaks found
Comment 2 mitz 2008-09-23 20:30:56 PDT
(In reply to comment #1)
> I don't see any leaks when I run the animation tests:
> wktests --debug --leaks LayoutTests/animations/
> animations ..............
>  ? checking for leaks in DumpRenderTree
>  - no leaks found

The leaks bot is running Tiger. The leaks command tends to be better at finding leaks under Tiger, which is what the leaks bot is running. There is also a chance that the leaks has been fixed since r36763.
Comment 3 Simon Fraser (smfr) 2008-09-24 12:10:04 PDT
Adding some printfs shows that RenderStyles are being leaked, but that may change when Chris fixes bug 20995.
Comment 4 Simon Fraser (smfr) 2008-09-29 14:38:46 PDT
Still leaking after bug 20995 landed. We're leaking RenderStyles:

...
	WebCore::Element::attach()
	WebCore::Node::createRendererIfNeeded()
	WebCore::Node::styleForRenderer(WebCore::RenderObject*)
	WebCore::CSSStyleSelector::styleForElement(WebCore::Element*, WebCore::RenderStyle*, bool, bool)
	WebCore::RenderStyle::operator new(unsigned long, WebCore::RenderArena*)
	WebCore::RenderArena::allocate(unsigned long)
	malloc
Comment 5 Simon Fraser (smfr) 2008-09-29 14:57:48 PDT
Created attachment 23920 [details]
Patch, changelog
Comment 6 Anders Carlsson 2008-09-29 15:03:34 PDT
Comment on attachment 23920 [details]
Patch, changelog

r=me
Comment 7 Simon Fraser (smfr) 2008-09-29 15:04:58 PDT
Committed r37078
	M	WebCore/ChangeLog
	M	WebCore/css/CSSStyleSelector.cpp
	M	WebCore/page/animation/KeyframeAnimation.cpp
r37078 = 8a565534699cd0513050a291fd34f009602cd903 (trunk)


Ran various animation tests with this fix, saw no leaks.