⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 246085 in webkit


Ignore:
Timestamp:
Jun 4, 2019, 3:56:37 PM (7 years ago)
Author:
ddkilzer@apple.com
Message:

REGRESSION (r244557): Leak of WKNSString in WTR::runOpenPanel() while running WebKit layout tests
<https://webkit.org/b/198538>
<rdar://problem/51407719>

Reviewed by Darin Adler.

  • WebKitTestRunner/TestController.cpp:

(WTR::runOpenPanel): Use adoptWK() to fix the leak.

Location:
trunk/Tools
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r246082 r246085  
     12019-06-04  David Kilzer  <ddkilzer@apple.com>
     2
     3        REGRESSION (r244557): Leak of WKNSString in WTR::runOpenPanel() while running WebKit layout tests
     4        <https://webkit.org/b/198538>
     5        <rdar://problem/51407719>
     6
     7        Reviewed by Darin Adler.
     8
     9        * WebKitTestRunner/TestController.cpp:
     10        (WTR::runOpenPanel): Use adoptWK() to fix the leak.
     11
    1122019-06-04  Aakash Jain  <aakash_jain@apple.com>
    213
  • trunk/Tools/WebKitTestRunner/TestController.cpp

    r245733 r246085  
    205205   
    206206#if PLATFORM(IOS_FAMILY)
    207     WKStringRef displayString = WKURLCopyLastPathComponent(static_cast<WKURLRef>(firstItem));
     207    auto displayString = adoptWK(WKURLCopyLastPathComponent(static_cast<WKURLRef>(firstItem)));
    208208    WKDataRef mediaIcon = TestController::singleton().openPanelFileURLsMediaIcon();
    209209   
    210210    if (mediaIcon) {
    211211        if (WKOpenPanelParametersGetAllowsMultipleFiles(parameters)) {
    212             WKOpenPanelResultListenerChooseMediaFiles(resultListenerRef, fileURLs, displayString, mediaIcon);
     212            WKOpenPanelResultListenerChooseMediaFiles(resultListenerRef, fileURLs, displayString.get(), mediaIcon);
    213213            return;
    214214        }
    215215       
    216         WKOpenPanelResultListenerChooseMediaFiles(resultListenerRef, adoptWK(WKArrayCreate(&firstItem, 1)).get(), displayString, mediaIcon);
     216        WKOpenPanelResultListenerChooseMediaFiles(resultListenerRef, adoptWK(WKArrayCreate(&firstItem, 1)).get(), displayString.get(), mediaIcon);
    217217        return;
    218218    }
Note: See TracChangeset for help on using the changeset viewer.