зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1104165 followup, addressing review comment
This commit is contained in:
Родитель
d2b3cf770e
Коммит
dc08d9fe3d
|
@ -2400,9 +2400,11 @@ function URLBarSetURI(aURI) {
|
|||
}
|
||||
|
||||
function losslessDecodeURI(aURI) {
|
||||
var value = aURI.spec;
|
||||
if (aURI.schemeIs("moz-action"))
|
||||
throw new Error("losslessDecodeURI should never get a moz-action URI");
|
||||
|
||||
var value = aURI.spec;
|
||||
|
||||
// Try to decode as UTF-8 if there's no encoding sequence that we would break.
|
||||
if (!/%25(?:3B|2F|3F|3A|40|26|3D|2B|24|2C|23)/i.test(value))
|
||||
try {
|
||||
|
|
Загрузка…
Ссылка в новой задаче