Bug 1104165 followup, addressing review comment

This commit is contained in:
Dão Gottwald 2015-04-24 07:44:22 +02:00
Родитель d2b3cf770e
Коммит dc08d9fe3d
1 изменённых файлов: 3 добавлений и 1 удалений

Просмотреть файл

@ -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 {