Changeset 280562 in webkit
- Timestamp:
- Aug 2, 2021 3:04:46 PM (12 months ago)
- Location:
- trunk
- Files:
-
- 4 edited
-
Source/WebKit/ChangeLog (modified) (1 diff)
-
Source/WebKit/WebProcess/WebPage/WebPage.cpp (modified) (1 diff)
-
Tools/ChangeLog (modified) (1 diff)
-
Tools/TestWebKitAPI/Tests/WebKitCocoa/LoadAlternateHTMLString.mm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit/ChangeLog
r280558 r280562 1 2021-08-02 Alex Christensen <achristensen@webkit.org> 2 3 Don't change invalid baseURLs from loadData or loadHTMLString to about:blank 4 https://bugs.webkit.org/show_bug.cgi?id=228717 5 <rdar://79909343> 6 7 Reviewed by Chris Dumez. 8 9 r278737 fixed a compatibility bug from r272469 but introduced a crash when the base URL does not successfully parse. 10 r279450 fixed that crash but introduced a new behavior change that changes the URL to about:blank. This didn't seem 11 to change anything because window.location is about:blank with and without the change, but WKWebView.URL did change, 12 which broke at least one app. This undoes the functionality change from r279450 and keeps the crash fix, which are 13 both covered by API tests. I also manually verified this fixes the app in the radar. 14 15 * WebProcess/WebPage/WebPage.cpp: 16 (WebKit::WebPage::loadData): 17 1 18 2021-08-02 Devin Rousso <drousso@apple.com> 2 19 -
trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp
r280374 r280562 1760 1760 else { 1761 1761 baseURL = URL(URL(), loadParameters.baseURLString); 1762 if (baseURL.isValid()) { 1763 if (!baseURL.protocolIsInHTTPFamily()) 1764 LegacySchemeRegistry::registerURLSchemeAsHandledBySchemeHandler(baseURL.protocol().toString()); 1765 } else 1766 baseURL = aboutBlankURL(); 1762 if (baseURL.isValid() && !baseURL.protocolIsInHTTPFamily()) 1763 LegacySchemeRegistry::registerURLSchemeAsHandledBySchemeHandler(baseURL.protocol().toString()); 1767 1764 } 1768 1765 -
trunk/Tools/ChangeLog
r280560 r280562 1 2021-08-02 Alex Christensen <achristensen@webkit.org> 2 3 Don't change invalid baseURLs from loadData or loadHTMLString to about:blank 4 https://bugs.webkit.org/show_bug.cgi?id=228717 5 <rdar://79909343> 6 7 Reviewed by Chris Dumez. 8 9 * TestWebKitAPI/Tests/WebKitCocoa/LoadAlternateHTMLString.mm: 10 (TEST): 11 1 12 2021-08-02 Kevin Neal <kevin_neal@apple.com> 2 13 -
trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/LoadAlternateHTMLString.mm
r279450 r280562 196 196 [webView loadHTMLString:@"test" baseURL:[NSURL URLWithString:@"invalid"]]; 197 197 TestWebKitAPI::Util::run(&didFinishNavigation); 198 EXPECT_WK_STREQ([webView URL].absoluteString, "invalid"); 198 199 199 200 EXPECT_FALSE(didCrash);
Note: See TracChangeset
for help on using the changeset viewer.