From 6f3a5562a54415310133fca1907cdebb1f7fb068 Mon Sep 17 00:00:00 2001 From: zhangxin11112342 Date: Tue, 30 Apr 2024 09:10:36 +0800 Subject: [PATCH] =?UTF-8?q?fixed=20eb78641=20from=20https://gitee.com/zhan?= =?UTF-8?q?gxin11112342/chromium=5Fchrome/pulls/79=20fixed=2053fb7d9=20fro?= =?UTF-8?q?m=20https://gitee.com/zhangxin11112342/chromium=5Fchrome/pulls/?= =?UTF-8?q?77=20=E4=BF=AE=E5=A4=8DCVE-2024-3841?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: zhangxin11112342 --- browser/resources/browser_switch/app.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/browser/resources/browser_switch/app.ts b/browser/resources/browser_switch/app.ts index c3784d2b6..932403058 100644 --- a/browser/resources/browser_switch/app.ts +++ b/browser/resources/browser_switch/app.ts @@ -145,7 +145,7 @@ function getUrlHostname(url: string): string { const anchor = document.createElement('a'); anchor.href = url; // Return entire url if parsing failed (which means the URL is bogus). - return anchor.hostname || url; + return anchor.hostname || encodeURI(url); } function getProxy(): BrowserSwitchProxy { -- Gitee