Bug 113309 - FormData::deepCopy() could use Vector::uncheckedAppend()
Summary: FormData::deepCopy() could use Vector::uncheckedAppend()
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-03-26 07:22 PDT by Chris Dumez
Modified: 2013-03-26 08:20 PDT (History)
4 users (show)

See Also:


Attachments
Patch (2.72 KB, patch)
2013-03-26 07:26 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2013-03-26 07:22:27 PDT
FormData::deepCopy() currently calls reserveInitialCapacity() on the Vector but then uses the regular append() method.
We could use uncheckedAppend() instead and bypass capacity checks since we already know the capacity is sufficient.
Comment 1 Chris Dumez 2013-03-26 07:26:10 PDT
Created attachment 195084 [details]
Patch
Comment 2 WebKit Review Bot 2013-03-26 08:20:15 PDT
Comment on attachment 195084 [details]
Patch

Clearing flags on attachment: 195084

Committed r146884: <http://trac.webkit.org/changeset/146884>
Comment 3 WebKit Review Bot 2013-03-26 08:20:18 PDT
All reviewed patches have been landed.  Closing bug.