Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: f2599adbe88142f918a4302fdde68d4a01ba9e2a
https://github.com/WebKit/WebKit/commit/f2599adbe88142f918a4302fdde68d4a01ba9e2a
Author: Olivier Blin <[email protected]>
Date: 2024-02-02 (Fri, 02 Feb 2024)
Changed paths:
M Source/WebKit/UIProcess/soup/WebProcessPoolSoup.cpp
Log Message:
-----------
REGRESSION (234750@main): [GTK][WPE] preferred language not passed to
NetworkProcess if set in WebContext before creating WebView
https://bugs.webkit.org/show_bug.cgi?id=268479
Reviewed by Adrian Perez de Castro.
In GLib ports, since 234750@main, the user preferred language is not
properly passed to the NetworkProcess if it is set in WebContext
before creating the WebView.
This causes a wrong Accept-Language header in HTTP requests sent with libsoup.
The webkit_web_context_set_preferred_languages() API can be called
before passing the WebContext at WebView creation.
Since 234750@main, this function calls the setOverrideLanguages()
WebProcessPool API instead of the overrideUserPreferredLanguages() WTF API.
So WebProcessPool::platformInitializeNetworkProcess() could not get the
real preferred language from the userPreferredLanguages() WTF API.
Instead, the NetworkProcess creation should use the overrideLanguages()
WebProcessPool API, like already done for the WebProcess creation
parameters (see also 226031@main).
Keep userPreferredLanguages() as a fallback to get the default
language from platformLanguage() in WTF::LanguageUnix.
* Source/WebKit/UIProcess/soup/WebProcessPoolSoup.cpp:
(WebKit::WebProcessPool::platformInitializeNetworkProcess):
Canonical link: https://commits.webkit.org/274011@main
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes