Changeset 29814 in webkit


Ignore:
Timestamp:
Jan 26, 2008 8:10:18 PM (16 years ago)
Author:
mrowe@apple.com
Message:

Fix leaks seen after loading <http://www.funnyordie.com/videos/d70b5a11cb>.

Reviewed by Darin Adler.

  • Misc/WebNSDataExtras.m:

(-[NSString _web_capitalizeRFC822HeaderFieldName]): Transfer ownerhip of the allocated buffers
to the new CFString so that they will be freed when no longer needed.

Location:
trunk/WebKit/mac
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKit/mac/ChangeLog

    r29811 r29814  
     12008-01-26  Mark Rowe  <mrowe@apple.com>
     2
     3        Reviewed by Darin Adler.
     4
     5        Fix leaks seen after loading <http://www.funnyordie.com/videos/d70b5a11cb>.
     6
     7        * Misc/WebNSDataExtras.m:
     8        (-[NSString _web_capitalizeRFC822HeaderFieldName]): Transfer ownerhip of the allocated buffers
     9        to the new CFString so that they will be freed when no longer needed.
     10
    1112008-01-26  Greg Bolsinga  <bolsinga@apple.com>
    212
  • trunk/WebKit/mac/Misc/WebNSDataExtras.m

    r15698 r29814  
    9393    if (somethingChanged) {
    9494        if (useUniCharPtr) {
    95             result = (NSString *)CFMakeCollectable(CFStringCreateWithCharacters(NULL, uniCharPtr, len));
     95            result = (NSString *)CFMakeCollectable(CFStringCreateWithCharactersNoCopy(NULL, uniCharPtr, len, NULL));
    9696        }
    9797        else {
    98             result = (NSString *)CFMakeCollectable(CFStringCreateWithCString(NULL, charPtr, kCFStringEncodingISOLatin1));
     98            result = (NSString *)CFMakeCollectable(CFStringCreateWithCStringNoCopy(NULL, charPtr, kCFStringEncodingISOLatin1, NULL));
    9999        }
    100100    }
Note: See TracChangeset for help on using the changeset viewer.