diff --git a/DEPS b/DEPS index f675ed670437..ca4d22173b89 100644 --- a/DEPS +++ b/DEPS @@ -2,7 +2,7 @@ gclient_gn_args_from = 'src' vars = { 'chromium_version': - '140.0.7309.0', + '140.0.7312.0', 'node_version': 'v22.17.1', 'nan_version': diff --git a/patches/chromium/build_allow_electron_mojom_interfaces_to_depend_on_blink.patch b/patches/chromium/build_allow_electron_mojom_interfaces_to_depend_on_blink.patch index 951309f2eb2d..fc1985b635fa 100644 --- a/patches/chromium/build_allow_electron_mojom_interfaces_to_depend_on_blink.patch +++ b/patches/chromium/build_allow_electron_mojom_interfaces_to_depend_on_blink.patch @@ -10,10 +10,10 @@ Needed for: 2) //electron/shell/common:web_contents_utility diff --git a/content/public/common/BUILD.gn b/content/public/common/BUILD.gn -index 950646641fa53cc690db65f81c07aab30c3cf7c6..4afa6a16d888b297b150b32b2a9f795541c560bf 100644 +index 647c4457217c87cfc1dfaeb99b2f2b66395cbfe4..3b9a57ec56b34673f684ac19a0324c775b3040c2 100644 --- a/content/public/common/BUILD.gn +++ b/content/public/common/BUILD.gn -@@ -382,6 +382,8 @@ mojom("interfaces") { +@@ -383,6 +383,8 @@ mojom("interfaces") { "//content/common/*", "//extensions/common:mojom", "//extensions/common:mojom_blink", diff --git a/patches/chromium/build_do_not_depend_on_packed_resource_integrity.patch b/patches/chromium/build_do_not_depend_on_packed_resource_integrity.patch index 91c221cbd270..71af2e116b7c 100644 --- a/patches/chromium/build_do_not_depend_on_packed_resource_integrity.patch +++ b/patches/chromium/build_do_not_depend_on_packed_resource_integrity.patch @@ -33,7 +33,7 @@ index 2fb245ad4daabdf430be1f593e73b2da90504419..2f7cd882b6c6d893917b1f7850ee0843 "//base", "//build:branding_buildflags", diff --git a/chrome/browser/BUILD.gn b/chrome/browser/BUILD.gn -index 40660c2e292cb0559ebef28ab1172eb6871c5423..0d8cac8fe3a75e823400ae819bbb6edaefbafdb6 100644 +index d090c2ac6d075915f7533ddcc3f75608fbaa18ea..29bd19809f7c50187b84fb9e6577df8e9aca8204 100644 --- a/chrome/browser/BUILD.gn +++ b/chrome/browser/BUILD.gn @@ -4760,7 +4760,7 @@ static_library("browser") { @@ -46,10 +46,10 @@ index 40660c2e292cb0559ebef28ab1172eb6871c5423..0d8cac8fe3a75e823400ae819bbb6eda # than here in :chrome_dll. deps += [ "//chrome:packed_resources_integrity_header" ] diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn -index a11499f0976966d1941e7da6621343a2cce34ead..786febeb58506ce70b0557bbee9060183f108caa 100644 +index b4592a79623dc2659a75249b716085e88b483955..de666e79b0d5f261ab1528593e0b85b74cae8bb6 100644 --- a/chrome/test/BUILD.gn +++ b/chrome/test/BUILD.gn -@@ -7455,9 +7455,12 @@ test("unit_tests") { +@@ -7458,9 +7458,12 @@ test("unit_tests") { "//chrome/notification_helper", ] @@ -63,7 +63,7 @@ index a11499f0976966d1941e7da6621343a2cce34ead..786febeb58506ce70b0557bbee906018 "//chrome//services/util_win:unit_tests", "//chrome/app:chrome_dll_resources", "//chrome/app:win_unit_tests", -@@ -8388,6 +8391,10 @@ test("unit_tests") { +@@ -8391,6 +8394,10 @@ test("unit_tests") { "../browser/performance_manager/policies/background_tab_loading_policy_unittest.cc", ] @@ -74,7 +74,7 @@ index a11499f0976966d1941e7da6621343a2cce34ead..786febeb58506ce70b0557bbee906018 sources += [ # The importer code is not used on Android. "../common/importer/firefox_importer_utils_unittest.cc", -@@ -8443,7 +8450,6 @@ test("unit_tests") { +@@ -8446,7 +8453,6 @@ test("unit_tests") { # TODO(crbug.com/417513088): Maybe merge with the non-android `deps` declaration above? deps += [ "../browser/screen_ai:screen_ai_install_state", diff --git a/patches/chromium/expose_setuseragent_on_networkcontext.patch b/patches/chromium/expose_setuseragent_on_networkcontext.patch index c77a89ca0f7b..301c977e94b1 100644 --- a/patches/chromium/expose_setuseragent_on_networkcontext.patch +++ b/patches/chromium/expose_setuseragent_on_networkcontext.patch @@ -33,7 +33,7 @@ index 0ab8187b0db8ae6db46d81738f653a2bc4c566f6..de3d55e85c22317f7f9375eb94d0d5d4 } // namespace net diff --git a/services/network/network_context.cc b/services/network/network_context.cc -index 4358fcc3dd45e6801b034b21c4ff29144501b719..09f80b28b68a47aec778183d46f1e847649b241b 100644 +index 3f62466413bf1df98ecbd70633123d7c652a61dc..2cbc92cab0bf5affbc1f655d96b805dcaf670150 100644 --- a/services/network/network_context.cc +++ b/services/network/network_context.cc @@ -1872,6 +1872,13 @@ void NetworkContext::SetNetworkConditions( diff --git a/patches/chromium/feat_add_signals_when_embedder_cleanup_callbacks_run_for.patch b/patches/chromium/feat_add_signals_when_embedder_cleanup_callbacks_run_for.patch index 5b39f8eff47e..ae96bcf174f0 100644 --- a/patches/chromium/feat_add_signals_when_embedder_cleanup_callbacks_run_for.patch +++ b/patches/chromium/feat_add_signals_when_embedder_cleanup_callbacks_run_for.patch @@ -25,7 +25,7 @@ Refs https://issues.chromium.org/issues/40210365 which is blocked on https://issues.chromium.org/issues/42203693 diff --git a/gin/isolate_holder.cc b/gin/isolate_holder.cc -index d1b95149ea0d16af2606900f10898a355026ffe1..fe1d866cba3b1a221092e1d6dced027894b3f3af 100644 +index 5255c1094c88761c19af1ea294ceccaca63b5ae4..bb1639d73070a99984b72eb61afd001dec5b08ff 100644 --- a/gin/isolate_holder.cc +++ b/gin/isolate_holder.cc @@ -35,6 +35,8 @@ v8::ArrayBuffer::Allocator* g_array_buffer_allocator = nullptr; @@ -37,7 +37,7 @@ index d1b95149ea0d16af2606900f10898a355026ffe1..fe1d866cba3b1a221092e1d6dced0278 std::unique_ptr getModifiedIsolateParams( std::unique_ptr params, -@@ -205,10 +207,26 @@ IsolateHolder::getDefaultIsolateParams() { +@@ -203,10 +205,26 @@ IsolateHolder::getDefaultIsolateParams() { return params; } diff --git a/patches/chromium/feat_configure_launch_options_for_service_process.patch b/patches/chromium/feat_configure_launch_options_for_service_process.patch index cc158edcffc5..7fdf5649b402 100644 --- a/patches/chromium/feat_configure_launch_options_for_service_process.patch +++ b/patches/chromium/feat_configure_launch_options_for_service_process.patch @@ -273,7 +273,7 @@ index 11846daf710f7cc272da17f14b8813fea93fe7e6..136fa55e7945f1d6abf5731c9cbaa921 #if BUILDFLAG(IS_WIN) if (!options_.preload_libraries_.empty()) { diff --git a/content/browser/service_host/utility_process_host.h b/content/browser/service_host/utility_process_host.h -index a0995700d414f3126d11ae2cf4c02b06b820a06e..5b3e1c8cf09b7135443c056c27239fb9ef3fd9c9 100644 +index 580fa663e729a43bef44a10de8983c4aecc312fb..f39af3df87786a472f987309ac0dea699b9f0d9f 100644 --- a/content/browser/service_host/utility_process_host.h +++ b/content/browser/service_host/utility_process_host.h @@ -31,6 +31,7 @@ @@ -284,7 +284,7 @@ index a0995700d414f3126d11ae2cf4c02b06b820a06e..5b3e1c8cf09b7135443c056c27239fb9 #endif // BUILDFLAG(IS_WIN) namespace base { -@@ -134,14 +135,31 @@ class CONTENT_EXPORT UtilityProcessHost +@@ -134,14 +135,31 @@ class CONTENT_EXPORT UtilityProcessHost final std::variant file); #endif @@ -319,7 +319,7 @@ index a0995700d414f3126d11ae2cf4c02b06b820a06e..5b3e1c8cf09b7135443c056c27239fb9 // Requests that the process bind a receiving pipe targeting the interface // named by `receiver`. Calls to this method generally end up in // `ChildThreadImpl::OnBindReceiver()` and the option is used for testing -@@ -185,6 +203,27 @@ class CONTENT_EXPORT UtilityProcessHost +@@ -185,6 +203,27 @@ class CONTENT_EXPORT UtilityProcessHost final std::optional> zygote_for_testing_; #endif // BUILDFLAG(USE_ZYGOTE) diff --git a/patches/chromium/feat_corner_smoothing_css_rule_and_blink_painting.patch b/patches/chromium/feat_corner_smoothing_css_rule_and_blink_painting.patch index d3881aab7dfe..8c06c521486f 100644 --- a/patches/chromium/feat_corner_smoothing_css_rule_and_blink_painting.patch +++ b/patches/chromium/feat_corner_smoothing_css_rule_and_blink_painting.patch @@ -130,10 +130,10 @@ index 2f7d7fbb8d95791dd287170b9f99dd420cfa9487..b705afe19cbb3a39a42a869eb994e7aa } // namespace css_longhand } // namespace blink diff --git a/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc b/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc -index 8f3031a26ad1e50d7658319360734ea58e78d6d0..a524bb02db69f5716a37d392e9f63e5a24ad1f73 100644 +index e92887580b37210c86b33b3ce18052cfd6a3f674..84bd1305ed1b278501df27acf153144c3f146a72 100644 --- a/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc +++ b/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc -@@ -4013,6 +4013,15 @@ PositionTryFallback StyleBuilderConverter::ConvertSinglePositionTryFallback( +@@ -4033,6 +4033,15 @@ PositionTryFallback StyleBuilderConverter::ConvertSinglePositionTryFallback( return PositionTryFallback(scoped_name, tactic_list); } @@ -150,10 +150,10 @@ index 8f3031a26ad1e50d7658319360734ea58e78d6d0..a524bb02db69f5716a37d392e9f63e5a const CSSValue& value) { const auto& list = To(value); diff --git a/third_party/blink/renderer/core/css/resolver/style_builder_converter.h b/third_party/blink/renderer/core/css/resolver/style_builder_converter.h -index 047757180c5af2a45296d347b44cec156d74c65d..24a607ac9f49176dac2c14da85f0ca85f87b1189 100644 +index 40123605bcd044d11ffa643c9ed0a182795059b3..ff3153cbe24212e844b34b5829dacf1a84bb06b8 100644 --- a/third_party/blink/renderer/core/css/resolver/style_builder_converter.h +++ b/third_party/blink/renderer/core/css/resolver/style_builder_converter.h -@@ -431,6 +431,7 @@ class StyleBuilderConverter { +@@ -434,6 +434,7 @@ class StyleBuilderConverter { static PositionTryFallback ConvertSinglePositionTryFallback( StyleResolverState&, const CSSValue&); @@ -312,7 +312,7 @@ index 7e3d46902fbf736b4240eb3fcb89975a7b222197..57fdc89fc265ad70cb0bff8443cc1026 auto DrawAsSinglePath = [&]() { diff --git a/third_party/blink/renderer/platform/runtime_enabled_features.json5 b/third_party/blink/renderer/platform/runtime_enabled_features.json5 -index 4ca6cbc36ce4e183d3291c1a03b89b0a58fc5810..8811ec2ffed7e11c9ee4e25a4491568c55cd95a6 100644 +index 52ae779fed980c7fb06d770fd3395d56c247b065..664c87d634730b22369007922c967a4089635197 100644 --- a/third_party/blink/renderer/platform/runtime_enabled_features.json5 +++ b/third_party/blink/renderer/platform/runtime_enabled_features.json5 @@ -214,6 +214,10 @@ diff --git a/patches/chromium/feat_enable_passing_exit_code_on_service_process_crash.patch b/patches/chromium/feat_enable_passing_exit_code_on_service_process_crash.patch index 68760147cfea..39e40f7506f6 100644 --- a/patches/chromium/feat_enable_passing_exit_code_on_service_process_crash.patch +++ b/patches/chromium/feat_enable_passing_exit_code_on_service_process_crash.patch @@ -97,10 +97,10 @@ index 136fa55e7945f1d6abf5731c9cbaa92148f8117d..ba6dbc588c809c482770d2f78d1cd97e std::optional UtilityProcessHost::GetServiceName() { diff --git a/content/browser/service_host/utility_process_host.h b/content/browser/service_host/utility_process_host.h -index 5b3e1c8cf09b7135443c056c27239fb9ef3fd9c9..b33f3f7ea5e92b8dc63fec0acdb4d9eaea57af99 100644 +index f39af3df87786a472f987309ac0dea699b9f0d9f..6f470d19fa5fa0bd4d2bdb1be4aa0cb3a70d3936 100644 --- a/content/browser/service_host/utility_process_host.h +++ b/content/browser/service_host/utility_process_host.h -@@ -88,7 +88,7 @@ class CONTENT_EXPORT UtilityProcessHost +@@ -88,7 +88,7 @@ class CONTENT_EXPORT UtilityProcessHost final virtual void OnProcessTerminatedNormally() {} // Called when the process has terminated due to a crash. The `type` field // indicates the type of crash. See above. diff --git a/patches/chromium/gin_enable_disable_v8_platform.patch b/patches/chromium/gin_enable_disable_v8_platform.patch index 17c60f34d3eb..4157c23a046a 100644 --- a/patches/chromium/gin_enable_disable_v8_platform.patch +++ b/patches/chromium/gin_enable_disable_v8_platform.patch @@ -7,7 +7,7 @@ We don't use gin to create the V8 platform, because we need to inject Node things. diff --git a/gin/isolate_holder.cc b/gin/isolate_holder.cc -index b3416c90c9071d8d32d30ecf257b64f133b2ae07..8632f1c18b407bb7832900bcebadacb3707224ac 100644 +index 079e9db7df8e47904c337783f7f75d7ea3b3d643..528abd094dd501e462fd197bfd69379e11ba9eaf 100644 --- a/gin/isolate_holder.cc +++ b/gin/isolate_holder.cc @@ -162,11 +162,13 @@ void IsolateHolder::Initialize(ScriptMode mode, diff --git a/patches/chromium/gritsettings_resource_ids.patch b/patches/chromium/gritsettings_resource_ids.patch index 2a8bc97e46a6..b6f5570911ce 100644 --- a/patches/chromium/gritsettings_resource_ids.patch +++ b/patches/chromium/gritsettings_resource_ids.patch @@ -6,7 +6,7 @@ Subject: gritsettings_resource_ids.patch Add electron resources file to the list of resource ids generation. diff --git a/tools/gritsettings/resource_ids.spec b/tools/gritsettings/resource_ids.spec -index 7693ff03125e2c4a7a02d19c4a0096b2ee566e48..2417a0e46102202f0e696c47cdd6d84b248dabfd 100644 +index 40441331934df92b9903c005065e6eedcfed69e1..96fc4ccc3f1dd65cf59df4a32adb587193afe6d0 100644 --- a/tools/gritsettings/resource_ids.spec +++ b/tools/gritsettings/resource_ids.spec @@ -1547,6 +1547,11 @@ diff --git a/patches/chromium/isolate_holder.patch b/patches/chromium/isolate_holder.patch index 7087da0b28b5..074d7d51f3f9 100644 --- a/patches/chromium/isolate_holder.patch +++ b/patches/chromium/isolate_holder.patch @@ -15,7 +15,7 @@ for us to register the isolate in between Isolate::Allocate and Isolate::Initialize. diff --git a/gin/isolate_holder.cc b/gin/isolate_holder.cc -index 8632f1c18b407bb7832900bcebadacb3707224ac..d1b95149ea0d16af2606900f10898a355026ffe1 100644 +index 528abd094dd501e462fd197bfd69379e11ba9eaf..5255c1094c88761c19af1ea294ceccaca63b5ae4 100644 --- a/gin/isolate_holder.cc +++ b/gin/isolate_holder.cc @@ -81,7 +81,8 @@ IsolateHolder::IsolateHolder( diff --git a/patches/chromium/mas_avoid_private_macos_api_usage.patch.patch b/patches/chromium/mas_avoid_private_macos_api_usage.patch.patch index c6a94b1a00d9..b06d525048e9 100644 --- a/patches/chromium/mas_avoid_private_macos_api_usage.patch.patch +++ b/patches/chromium/mas_avoid_private_macos_api_usage.patch.patch @@ -35,7 +35,7 @@ system font by checking if it's kCTFontPriorityAttribute is set to system priority. diff --git a/base/BUILD.gn b/base/BUILD.gn -index 7f7c60a6777c72c76eff5a261e0af12c2a244634..d928082d92b96dc0b33cec9c6942baa8830239e1 100644 +index 4f6afc75d3cbeda40b34442153653beecd09767c..e08e5b83dad4d2e6f6b0c09303718c16f2ddcef9 100644 --- a/base/BUILD.gn +++ b/base/BUILD.gn @@ -1055,6 +1055,7 @@ component("base") { @@ -715,7 +715,7 @@ index ef3b5ceba5e460cdfc609245a53d6d1720f32564..910043ba8cc79774550c0097f5bef53e defines = [] diff --git a/content/renderer/BUILD.gn b/content/renderer/BUILD.gn -index 00210ede4f315e9c694a4f477eedd316c2e0c23b..b2557fa60946176ad38edafcd874b5d3a8276c10 100644 +index f6ebfaf945c0b024f18e5e09f04dfa43caf63e22..c8e241cdeac0bfbfe715404722aab6d6d1ded2f1 100644 --- a/content/renderer/BUILD.gn +++ b/content/renderer/BUILD.gn @@ -319,6 +319,7 @@ target(link_target_type, "renderer") { @@ -1874,10 +1874,10 @@ index fe3f85073e31de487a08e57d7f9b07aa4eccf8f3..cf5b07203c8bd559a404600cc98cc8ec // enough. return PlatformFontMac::SystemFontType::kGeneral; diff --git a/ui/views/BUILD.gn b/ui/views/BUILD.gn -index b57de34473e7a5615c176ad22a99b3fa028c50ba..fcec8ef135d6aa9bd30f191e51ff98cf8701b027 100644 +index 88c3981b7be09054de9496ff81fcb9db206235b5..b4917fdc2fb6f6f75f1c6696c5bb2386ee2d0a0b 100644 --- a/ui/views/BUILD.gn +++ b/ui/views/BUILD.gn -@@ -719,6 +719,8 @@ component("views") { +@@ -721,6 +721,8 @@ component("views") { "IOSurface.framework", "QuartzCore.framework", ] @@ -1886,7 +1886,7 @@ index b57de34473e7a5615c176ad22a99b3fa028c50ba..fcec8ef135d6aa9bd30f191e51ff98cf } if (is_win) { -@@ -1148,6 +1150,8 @@ source_set("test_support") { +@@ -1150,6 +1152,8 @@ source_set("test_support") { "//ui/base/mojom:ui_base_types", ] diff --git a/patches/chromium/network_service_allow_remote_certificate_verification_logic.patch b/patches/chromium/network_service_allow_remote_certificate_verification_logic.patch index 578ecc7bc5b4..881724c73f85 100644 --- a/patches/chromium/network_service_allow_remote_certificate_verification_logic.patch +++ b/patches/chromium/network_service_allow_remote_certificate_verification_logic.patch @@ -7,7 +7,7 @@ This adds a callback from the network service that's used to implement session.setCertificateVerifyCallback. diff --git a/services/network/network_context.cc b/services/network/network_context.cc -index 0715ffeda932d5ef8b5c90008ada8e84efbff765..4358fcc3dd45e6801b034b21c4ff29144501b719 100644 +index c08fedd7b86671c6102e8de0564187b613df5cd9..3f62466413bf1df98ecbd70633123d7c652a61dc 100644 --- a/services/network/network_context.cc +++ b/services/network/network_context.cc @@ -165,6 +165,11 @@ diff --git a/patches/chromium/preconnect_manager.patch b/patches/chromium/preconnect_manager.patch index fb3c8e892fc4..daa869f1a333 100644 --- a/patches/chromium/preconnect_manager.patch +++ b/patches/chromium/preconnect_manager.patch @@ -6,26 +6,14 @@ Subject: Preconnect manager * Patch disables the profile related changes added in https://chromium-review.googlesource.com/c/chromium/src/+/3928470. -diff --git a/chrome/browser/predictors/preconnect_manager.h b/chrome/browser/predictors/preconnect_manager.h -index 9fe1c93b5cf2a5e7551f070d1d1d01683350675d..6ec8305948c3e2552775a458621c7794f839d09c 100644 ---- a/chrome/browser/predictors/preconnect_manager.h -+++ b/chrome/browser/predictors/preconnect_manager.h -@@ -8,7 +8,6 @@ - #include - - #include "base/memory/weak_ptr.h" --#include "chrome/browser/predictors/resource_prefetch_predictor.h" - #include "content/public/browser/preconnect_request.h" - #include "content/public/browser/storage_partition_config.h" - #include "mojo/public/cpp/bindings/receiver.h" diff --git a/chrome/browser/predictors/preconnect_manager_impl.cc b/chrome/browser/predictors/preconnect_manager_impl.cc -index 639247fec01823ee942a1fb56f2511020ab0f228..6a625fcdd0ddcd55591a90126551f174c81889b1 100644 +index 57d544c0b03c80bdc015ce79d3aa78054d43c6e7..e9547e23d8bb2a5ac120c901405720cbde89737c 100644 --- a/chrome/browser/predictors/preconnect_manager_impl.cc +++ b/chrome/browser/predictors/preconnect_manager_impl.cc -@@ -14,9 +14,11 @@ +@@ -13,9 +13,11 @@ + #include "base/trace_event/trace_event.h" #include "base/types/optional_util.h" #include "chrome/browser/predictors/predictors_features.h" - #include "chrome/browser/predictors/predictors_traffic_annotations.h" +#if 0 #include "chrome/browser/predictors/resource_prefetch_predictor.h" #include "chrome/browser/preloading/preloading_prefs.h" @@ -34,7 +22,7 @@ index 639247fec01823ee942a1fb56f2511020ab0f228..6a625fcdd0ddcd55591a90126551f174 #include "content/public/browser/browser_context.h" #include "content/public/browser/browser_task_traits.h" #include "content/public/browser/browser_thread.h" -@@ -105,12 +107,15 @@ PreconnectManagerImpl::PreconnectManagerImpl( +@@ -106,12 +108,15 @@ PreconnectManagerImpl::PreconnectManagerImpl( PreconnectManagerImpl::~PreconnectManagerImpl() = default; bool PreconnectManagerImpl::IsEnabled() { @@ -50,17 +38,3 @@ index 639247fec01823ee942a1fb56f2511020ab0f228..6a625fcdd0ddcd55591a90126551f174 } base::WeakPtr PreconnectManagerImpl::GetWeakPtr() { -diff --git a/chrome/browser/predictors/preconnect_manager_impl.h b/chrome/browser/predictors/preconnect_manager_impl.h -index cf28c1c2572cf7c8c555ffdcb0e945b1b3c5d3ce..e057183ba0ec3ddf803302cf6e8418cb44b6b42a 100644 ---- a/chrome/browser/predictors/preconnect_manager_impl.h -+++ b/chrome/browser/predictors/preconnect_manager_impl.h -@@ -18,7 +18,9 @@ - #include "chrome/browser/predictors/preconnect_manager.h" - #include "chrome/browser/predictors/proxy_lookup_client_impl.h" - #include "chrome/browser/predictors/resolve_host_client_impl.h" -+#if 0 - #include "chrome/browser/predictors/resource_prefetch_predictor.h" -+#endif - #include "content/public/browser/preconnect_request.h" - #include "content/public/browser/storage_partition_config.h" - #include "net/base/network_anonymization_key.h" diff --git a/patches/chromium/revert_use_more_binaries_from_clang_toolchain_in_mac_build.patch b/patches/chromium/revert_use_more_binaries_from_clang_toolchain_in_mac_build.patch index 1d41e315b6ae..54e592256c13 100644 --- a/patches/chromium/revert_use_more_binaries_from_clang_toolchain_in_mac_build.patch +++ b/patches/chromium/revert_use_more_binaries_from_clang_toolchain_in_mac_build.patch @@ -14,7 +14,7 @@ This patch can be removed when both otool and nm are correctly persisted with third-party/llvm-build. diff --git a/DEPS b/DEPS -index 15a18361c468af57a286895448e39284d6d39bbe..559f7755314dd7dfbf74c89880a99b4a8e48ce74 100644 +index 2bb47b00aa69e2a5b6373a2821fdb876918108a9..bf69eef55d00b28e8df5a4eddd80e35a673a0020 100644 --- a/DEPS +++ b/DEPS @@ -906,13 +906,6 @@ deps = { diff --git a/patches/chromium/revert_views_remove_desktopwindowtreehostwin_window_enlargement.patch b/patches/chromium/revert_views_remove_desktopwindowtreehostwin_window_enlargement.patch index e35e7cc43c7d..436cdf0d87d9 100644 --- a/patches/chromium/revert_views_remove_desktopwindowtreehostwin_window_enlargement.patch +++ b/patches/chromium/revert_views_remove_desktopwindowtreehostwin_window_enlargement.patch @@ -10,10 +10,10 @@ on Windows. We should refactor our code so that this patch isn't necessary. diff --git a/testing/variations/fieldtrial_testing_config.json b/testing/variations/fieldtrial_testing_config.json -index 7f5e8e161f7503c0bffe50304db1c73b987b9a2b..7c2c91b6571264dd02dc2cad8861a26c596f6980 100644 +index b087a48440b25561991ce4c4002bf0d9e2acf10e..7bbed72665f0bea9eff33cd4a7412b81621308e8 100644 --- a/testing/variations/fieldtrial_testing_config.json +++ b/testing/variations/fieldtrial_testing_config.json -@@ -24597,6 +24597,21 @@ +@@ -24561,6 +24561,21 @@ ] } ], diff --git a/patches/chromium/web_contents.patch b/patches/chromium/web_contents.patch index 8ccbe4d9b699..0e505bdfc19d 100644 --- a/patches/chromium/web_contents.patch +++ b/patches/chromium/web_contents.patch @@ -35,10 +35,10 @@ index 315e54d061dea3ce28583c6eb456196dc873a1a6..c6981b845253a81f3865ccd71f97bdc7 CHECK(view_.get()); diff --git a/content/public/browser/web_contents.h b/content/public/browser/web_contents.h -index 04c72f708b0fc8b2e45c834d8f40753718860f00..42ceaff9c5c8b15645ebe31f610ba779146d4a8c 100644 +index 07165bf281f91ebda0dd34ac1a30b35db333352e..2a4f0f0e52287e75e70196960574da929ce6c35f 100644 --- a/content/public/browser/web_contents.h +++ b/content/public/browser/web_contents.h -@@ -127,11 +127,14 @@ class PrerenderHandle; +@@ -126,11 +126,14 @@ class PrerenderHandle; class RenderFrameHost; class RenderViewHost; class RenderWidgetHost; @@ -53,7 +53,7 @@ index 04c72f708b0fc8b2e45c834d8f40753718860f00..42ceaff9c5c8b15645ebe31f610ba779 class WebUI; struct DropData; struct MHTMLGenerationParams; -@@ -285,6 +288,10 @@ class WebContents : public PageNavigator, public base::SupportsUserData { +@@ -284,6 +287,10 @@ class WebContents : public PageNavigator, public base::SupportsUserData { network::mojom::WebSandboxFlags starting_sandbox_flags = network::mojom::WebSandboxFlags::kNone; diff --git a/patches/chromium/worker_context_will_destroy.patch b/patches/chromium/worker_context_will_destroy.patch index 1238aec49598..d7fa271c4e76 100644 --- a/patches/chromium/worker_context_will_destroy.patch +++ b/patches/chromium/worker_context_will_destroy.patch @@ -67,7 +67,7 @@ index dfc5c935005bf8fb59d4bf5dd6dcb31468128cd6..4b8c2223d4d7eebe88c54d232ac8f8e2 const WebSecurityOrigin& script_origin) { return false; diff --git a/third_party/blink/renderer/core/workers/worker_thread.cc b/third_party/blink/renderer/core/workers/worker_thread.cc -index 0ecbc9efc6b58ca605ec9b2d917b24b823b2c1e8..8587f9b9bf62b48271ce5a43f4402ba193672f5e 100644 +index 8aaf3c12144273bb35bba3e77e0fd505282213df..a6eab67460b49b4594440be2f6e41f852b201e12 100644 --- a/third_party/blink/renderer/core/workers/worker_thread.cc +++ b/third_party/blink/renderer/core/workers/worker_thread.cc @@ -823,6 +823,12 @@ void WorkerThread::PrepareForShutdownOnWorkerThread() { diff --git a/patches/devtools_frontend/chore_expose_ui_to_allow_electron_to_set_dock_side.patch b/patches/devtools_frontend/chore_expose_ui_to_allow_electron_to_set_dock_side.patch index b718aaefa8ca..dbfbd5c11ad9 100644 --- a/patches/devtools_frontend/chore_expose_ui_to_allow_electron_to_set_dock_side.patch +++ b/patches/devtools_frontend/chore_expose_ui_to_allow_electron_to_set_dock_side.patch @@ -10,10 +10,10 @@ to handle this without patching, but this is fairly clean for now and no longer patching legacy devtools code. diff --git a/front_end/entrypoints/main/MainImpl.ts b/front_end/entrypoints/main/MainImpl.ts -index 908271e753368265b2ea7deaeb67c72c3589b7ae..d9a21515b8a20a2fbee8ed3acc50491c9062101b 100644 +index 27011f3676688f0ad16962af6f1def9c23e24900..551c5307be04e6f2d8f63049d6dbb9a5793eec02 100644 --- a/front_end/entrypoints/main/MainImpl.ts +++ b/front_end/entrypoints/main/MainImpl.ts -@@ -732,6 +732,8 @@ export class MainImpl { +@@ -736,6 +736,8 @@ export class MainImpl { globalThis.Main = globalThis.Main || {}; // @ts-expect-error Exported for Tests.js globalThis.Main.Main = MainImpl; diff --git a/patches/node/fix_handle_boringssl_and_openssl_incompatibilities.patch b/patches/node/fix_handle_boringssl_and_openssl_incompatibilities.patch index d4dcdd86a202..999302e66455 100644 --- a/patches/node/fix_handle_boringssl_and_openssl_incompatibilities.patch +++ b/patches/node/fix_handle_boringssl_and_openssl_incompatibilities.patch @@ -17,7 +17,7 @@ Upstreams: - https://github.com/nodejs/node/pull/39136 diff --git a/deps/ncrypto/ncrypto.cc b/deps/ncrypto/ncrypto.cc -index 6f9406eecacb7411a2e84a7b51e60b726d1961f3..bffdb0259eeed7389adb54a8ff13a1ac4e767d90 100644 +index 6f9406eecacb7411a2e84a7b51e60b726d1961f3..a0cfb0bc3776dc3682cdb332ed418286d3243bd1 100644 --- a/deps/ncrypto/ncrypto.cc +++ b/deps/ncrypto/ncrypto.cc @@ -786,7 +786,7 @@ bool SafeX509SubjectAltNamePrint(const BIOPointer& out, X509_EXTENSION* ext) { @@ -110,7 +110,7 @@ index 6f9406eecacb7411a2e84a7b51e60b726d1961f3..bffdb0259eeed7389adb54a8ff13a1ac if (len + 2 != rem) return {}; return reinterpret_cast(buf + 3); +#endif -+ return nullptr; ++ return {}; } const std::string_view SSLPointer::getClientHelloServerName() const { @@ -128,7 +128,7 @@ index 6f9406eecacb7411a2e84a7b51e60b726d1961f3..bffdb0259eeed7389adb54a8ff13a1ac if (len + 2 > rem) return {}; return reinterpret_cast(buf + 5); +#endif -+ return nullptr; ++ return {}; } std::optional SSLPointer::GetServerName( diff --git a/shell/browser/api/electron_api_session.cc b/shell/browser/api/electron_api_session.cc index e9fdf7d35801..0bc37db951ea 100644 --- a/shell/browser/api/electron_api_session.cc +++ b/shell/browser/api/electron_api_session.cc @@ -22,6 +22,7 @@ #include "base/uuid.h" #include "chrome/browser/browser_process.h" #include "chrome/browser/predictors/preconnect_manager.h" +#include "chrome/browser/predictors/predictors_traffic_annotations.h" // nogncheck #include "chrome/common/chrome_switches.h" #include "chrome/common/pref_names.h" #include "components/download/public/common/download_danger_type.h" @@ -1360,7 +1361,8 @@ static void StartPreconnectOnUI(ElectronBrowserContext* browser_context, {url::Origin::Create(url), num_sockets_to_preconnect, net::NetworkAnonymizationKey::CreateSameSite( net::SchemefulSite(origin))}}; - browser_context->GetPreconnectManager()->Start(url, requests); + browser_context->GetPreconnectManager()->Start( + url, requests, predictors::kLoadingPredictorPreconnectTrafficAnnotation); } void Session::Preconnect(const gin_helper::Dictionary& options, diff --git a/shell/browser/net/resolve_host_function.cc b/shell/browser/net/resolve_host_function.cc index c9db7c5c9391..e08e6ef6c393 100644 --- a/shell/browser/net/resolve_host_function.cc +++ b/shell/browser/net/resolve_host_function.cc @@ -54,8 +54,8 @@ void ResolveHostFunction::Run() { receiver_.set_disconnect_handler(base::BindOnce( &ResolveHostFunction::OnComplete, this, net::ERR_NAME_NOT_RESOLVED, net::ResolveErrorInfo(net::ERR_FAILED), - /*resolved_addresses=*/std::nullopt, - /*endpoint_results_with_metadata=*/std::nullopt)); + /*resolved_addresses=*/net::AddressList(), + /*endpoint_results_with_metadata=*/net::HostResolverEndpointResults())); if (electron::IsUtilityProcess()) { URLLoaderBundle::GetInstance()->GetHostResolver()->ResolveHost( network::mojom::HostResolverHost::NewHostPortPair( @@ -76,9 +76,8 @@ void ResolveHostFunction::Run() { void ResolveHostFunction::OnComplete( int result, const net::ResolveErrorInfo& resolve_error_info, - const std::optional& resolved_addresses, - const std::optional& - endpoint_results_with_metadata) { + const net::AddressList& resolved_addresses, + const net::HostResolverEndpointResults& endpoint_results_with_metadata) { DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); // Ensure that we outlive the `receiver_.reset()` call. diff --git a/shell/browser/net/resolve_host_function.h b/shell/browser/net/resolve_host_function.h index 56afad28bc86..f82a2291cdd3 100644 --- a/shell/browser/net/resolve_host_function.h +++ b/shell/browser/net/resolve_host_function.h @@ -51,8 +51,8 @@ class ResolveHostFunction // network::mojom::ResolveHostClient implementation void OnComplete(int result, const net::ResolveErrorInfo& resolve_error_info, - const std::optional& resolved_addresses, - const std::optional& + const net::AddressList& resolved_addresses, + const net::HostResolverEndpointResults& endpoint_results_with_metadata) override; SEQUENCE_CHECKER(sequence_checker_); diff --git a/shell/browser/ui/file_dialog_linux_portal.cc b/shell/browser/ui/file_dialog_linux_portal.cc index 7dd520d92bdf..bd2c986fb8ed 100644 --- a/shell/browser/ui/file_dialog_linux_portal.cc +++ b/shell/browser/ui/file_dialog_linux_portal.cc @@ -13,6 +13,9 @@ #include "base/no_destructor.h" #include "base/strings/string_number_conversions.h" #include "base/synchronization/atomic_flag.h" +#include "base/task/lazy_thread_pool_task_runner.h" +#include "base/task/single_thread_task_runner_thread_mode.h" +#include "base/task/task_traits.h" #include "components/dbus/thread_linux/dbus_thread_linux.h" #include "components/dbus/utils/check_for_service_and_start.h" #include "dbus/bus.h" @@ -37,6 +40,13 @@ constexpr char kXdgPortalRequiredVersionFlag[] = "xdg-portal-required-version"; bool g_portal_available = false; +// Refs +// https://source.chromium.org/chromium/chromium/src/+/main:components/dbus/thread_linux/dbus_thread_linux.cc;l=16-24;drc=1c281d7923af032d78ea7247e99b717dfebeb0b2 +base::LazyThreadPoolSingleThreadTaskRunner g_electron_dbus_thread_task_runner = + LAZY_THREAD_POOL_SINGLE_THREAD_TASK_RUNNER_INITIALIZER( + base::TaskTraits(base::MayBlock(), base::TaskPriority::USER_BLOCKING), + base::SingleThreadTaskRunnerThreadMode::SHARED); + struct FileChooserProperties : dbus::PropertySet { dbus::Property version; @@ -61,7 +71,7 @@ void CheckPortalAvailabilityOnBusThread() { dbus::Bus::Options options; options.bus_type = dbus::Bus::SESSION; options.connection_type = dbus::Bus::PRIVATE; - options.dbus_task_runner = dbus_thread_linux::GetTaskRunner(); + options.dbus_task_runner = g_electron_dbus_thread_task_runner.Get(); scoped_refptr bus = base::MakeRefCounted(options); dbus_utils::CheckForServiceAndStart( bus, kXdgPortalService, @@ -104,7 +114,7 @@ void StartPortalAvailabilityTestInBackground() { VLOG(1) << "Unable to parse --xdg-portal-required-version"; } - dbus_thread_linux::GetTaskRunner()->PostTask( + g_electron_dbus_thread_task_runner.Get()->PostTask( FROM_HERE, base::BindOnce(&CheckPortalAvailabilityOnBusThread)); }