Skip to content
Permalink
Browse files
39 bytes leaked in WTR::TestController::platformConfigureViewForTest()
https://bugs.webkit.org/show_bug.cgi?id=241525

Reviewed by Adrian Perez de Castro.

Plug a couple of leaks in the test controller.

* Tools/WebKitTestRunner/gtk/TestControllerGtk.cpp:
(WTR::TestController::platformConfigureViewForTest):
* Tools/WebKitTestRunner/wpe/TestControllerWPE.cpp:
(WTR::TestController::platformConfigureViewForTest):

Canonical link: https://commits.webkit.org/251494@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@295489 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
csaavedra committed Jun 13, 2022
1 parent b93bc2b commit ef8f6d8d76bb9011228805b57d2de2e8b8b47ec2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
@@ -143,7 +143,8 @@ const char* TestController::platformLibraryPathForTesting()

void TestController::platformConfigureViewForTest(const TestInvocation&)
{
WKPageSetApplicationNameForUserAgent(mainWebView()->page(), WKStringCreateWithUTF8CString("WebKitTestRunnerGTK"));
WKRetainPtr<WKStringRef> appName = adoptWK(WKStringCreateWithUTF8CString("WebKitTestRunnerGTK"));
WKPageSetApplicationNameForUserAgent(mainWebView()->page(), appName.get());
}

bool TestController::platformResetStateToConsistentValues(const TestOptions&)
@@ -133,7 +133,8 @@ const char* TestController::platformLibraryPathForTesting()

void TestController::platformConfigureViewForTest(const TestInvocation&)
{
WKPageSetApplicationNameForUserAgent(mainWebView()->page(), WKStringCreateWithUTF8CString("WebKitTestRunnerWPE"));
WKRetainPtr<WKStringRef> appName = adoptWK(WKStringCreateWithUTF8CString("WebKitTestRunnerWPE"));
WKPageSetApplicationNameForUserAgent(mainWebView()->page(), appName.get());
}

bool TestController::platformResetStateToConsistentValues(const TestOptions&)

0 comments on commit ef8f6d8

Please sign in to comment.