Bug 124595 - Get rid of bare new in SVGAnimatedColorAnimator::constructFromString()
Summary: Get rid of bare new in SVGAnimatedColorAnimator::constructFromString()
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sergio Correia (qrwteyrutiyoup)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-19 12:18 PST by Sergio Correia (qrwteyrutiyoup)
Modified: 2013-11-19 13:12 PST (History)
8 users (show)

See Also:


Attachments
Patch (30.67 KB, patch)
2013-11-19 12:20 PST, Sergio Correia (qrwteyrutiyoup)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sergio Correia (qrwteyrutiyoup) 2013-11-19 12:18:38 PST
Get rid of bare new in SVGAnimatedColorAnimator::constructFromString()
Comment 1 Sergio Correia (qrwteyrutiyoup) 2013-11-19 12:19:23 PST
Use std::unique_ptr instead, to manage the arguments passed to the create methods of SVGAnimatedType.
Comment 2 Sergio Correia (qrwteyrutiyoup) 2013-11-19 12:20:25 PST
Created attachment 217315 [details]
Patch
Comment 3 Darin Adler 2013-11-19 12:46:32 PST
Comment on attachment 217315 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=217315&action=review

> Source/WebCore/svg/SVGAnimatedTypeAnimator.h:79
> +        executeAction<AnimValType>(StartAnimationAction, animatedTypes, 0, copy.get());

Given this call site, looks like executeAction should be taking a reference rather than a pointer. Some day we should make that change.
Comment 4 WebKit Commit Bot 2013-11-19 13:12:08 PST
Comment on attachment 217315 [details]
Patch

Clearing flags on attachment: 217315

Committed r159516: <http://trac.webkit.org/changeset/159516>
Comment 5 WebKit Commit Bot 2013-11-19 13:12:11 PST
All reviewed patches have been landed.  Closing bug.