Bug 62763 - WKSecurityOriginGetProtocol and WKSecurityOriginGetHost are named wrong because they return copied strings
Summary: WKSecurityOriginGetProtocol and WKSecurityOriginGetHost are named wrong becau...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: John Sullivan
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2011-06-15 16:07 PDT by John Sullivan
Modified: 2011-06-15 16:18 PDT (History)
0 users

See Also:


Attachments
Patch to update the two names to correctly reflect their behavior. (2.66 KB, patch)
2011-06-15 16:10 PDT, John Sullivan
sam: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description John Sullivan 2011-06-15 16:07:29 PDT
WKSecurityOriginGetProtocol and WKSecurityOriginGetHost are named as if they return a pre-existing object, but they actually return copied strings.

This leads to leaks in callers that don't know to take ownership responsibility for the return values.

<rdar://problem/9618071>
Comment 1 John Sullivan 2011-06-15 16:10:09 PDT
Created attachment 97373 [details]
Patch to update the two names to correctly reflect their behavior.
Comment 2 John Sullivan 2011-06-15 16:18:57 PDT
http://trac.webkit.org/changeset/88983