diff --git a/patches/chromium/chore_disable_protocol_handler_dcheck.patch b/patches/chromium/chore_disable_protocol_handler_dcheck.patch index 98a7fa4019..dc7ea5f2ec 100644 --- a/patches/chromium/chore_disable_protocol_handler_dcheck.patch +++ b/patches/chromium/chore_disable_protocol_handler_dcheck.patch @@ -10,20 +10,18 @@ handlers. A DCHECK causes Electron to crash until we provide our own registry. This patch disables the check until we support this. diff --git a/extensions/browser/api/protocol_handlers/protocol_handlers_manager.cc b/extensions/browser/api/protocol_handlers/protocol_handlers_manager.cc -index 902cf488c7d84923365c4197a70b06e61e3af038..dce80684853f89a68a2d21997102f48feb3df8f8 100644 +index 7f26a1c3a63c8717705cbf6fe09ca3812450e15d..a0a483c7921553ce83be084f9a6dbd0c935c9fca 100644 --- a/extensions/browser/api/protocol_handlers/protocol_handlers_manager.cc +++ b/extensions/browser/api/protocol_handlers/protocol_handlers_manager.cc -@@ -129,7 +129,12 @@ void ProtocolHandlersManager::ProtocolHandlersSanityCheck() { +@@ -138,9 +138,9 @@ void ProtocolHandlersManager::ProtocolHandlersSanityCheck() { auto* ph_registry = ExtensionsBrowserClient::Get()->GetProtocolHandlerRegistry( browser_context_); -- DCHECK(ph_registry); -+ +- // Can be null for tests using dummy profiles. + // TODO(samuelmaddock): Add support for extensions protocol handler. For now, + // let's ignore this. -+ if (!ph_registry) -+ return; -+ + if (!ph_registry) { +- CHECK_IS_TEST(); + return; + } for (const auto& handler : ph_registry->GetExtensionProtocolHandlers()) { - DCHECK(handler.extension_id()); - if (!enabled_ids.contains(*handler.extension_id())) {