mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-23 21:01:08 +00:00
e740ed7de3
Patch by joaovanzuita, updated by Standard8. Differential Revision: https://phabricator.services.mozilla.com/D92333
20 lines
396 B
JavaScript
20 lines
396 B
JavaScript
// This is just a crashtest for a url that is rejected at parse time (port 80,000)
|
|
|
|
"use strict";
|
|
|
|
function run_test() {
|
|
// Bug 1301621 makes invalid ports throw
|
|
Assert.throws(
|
|
() => {
|
|
NetUtil.newChannel({
|
|
uri: "http://localhost:80000/",
|
|
loadUsingSystemPrincipal: true,
|
|
});
|
|
},
|
|
/NS_ERROR_MALFORMED_URI/,
|
|
"invalid port"
|
|
);
|
|
|
|
do_test_finished();
|
|
}
|