forked from mirrors/gecko-dev
Bug 1432870, r=bz
--HG-- extra : rebase_source : 0719a9b6d5833e73c7f23f923359674e40cd310e
This commit is contained in:
parent
a99bb3598e
commit
714c763d13
1 changed files with 6 additions and 0 deletions
|
|
@ -235,6 +235,12 @@ nsChromeRegistry::Canonify(nsIURL* aChromeURL)
|
|||
// path is already unescaped once, but uris can get unescaped twice
|
||||
const char* pos = path.BeginReading();
|
||||
const char* end = path.EndReading();
|
||||
// Must start with [a-zA-Z0-9].
|
||||
if (!('a' <= *pos && *pos <= 'z') &&
|
||||
!('A' <= *pos && *pos <= 'Z') &&
|
||||
!('0' <= *pos && *pos <= '9')) {
|
||||
return NS_ERROR_DOM_BAD_URI;
|
||||
}
|
||||
while (pos < end) {
|
||||
switch (*pos) {
|
||||
case ':':
|
||||
|
|
|
|||
Loading…
Reference in a new issue