Bug 158717 - [Cocoa] Avoid extra copy of headers dictionary in ResourceResponse::platformLazyInit()
Summary: [Cocoa] Avoid extra copy of headers dictionary in ResourceResponse::platformL...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-13 18:49 PDT by Chris Dumez
Modified: 2016-06-14 07:29 PDT (History)
4 users (show)

See Also:


Attachments
Patch (3.96 KB, patch)
2016-06-13 18:52 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 2016-06-13 18:49:23 PDT
Avoid extra copy of headers dictionary in ResourceResponse::platformLazyInit() by calling CFHTTPMessageCopyAllHeaderFields() instead of [NSURLResponse allHeaderFields].
Comment 1 Chris Dumez 2016-06-13 18:49:29 PDT
rdar://problem/26778863
Comment 2 Chris Dumez 2016-06-13 18:52:07 PDT
Created attachment 281224 [details]
Patch
Comment 3 Alex Christensen 2016-06-14 00:07:31 PDT
Comment on attachment 281224 [details]
Patch

Woohoo!!! Fewer copies!!! R=me

allHeaderFields is marked in the public API with @property (readonly, copy) NSDictionary *allHeaderFields;
Comment 4 WebKit Commit Bot 2016-06-14 07:29:49 PDT
Comment on attachment 281224 [details]
Patch

Clearing flags on attachment: 281224

Committed r202042: <http://trac.webkit.org/changeset/202042>
Comment 5 WebKit Commit Bot 2016-06-14 07:29:55 PDT
All reviewed patches have been landed.  Closing bug.