Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion url/src/parser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1368,7 +1368,7 @@ impl Parser<'_> {
break;
}
}
if scheme_type.is_file() {
if scheme_type.is_file() && self.context != Context::Setter {
// while url’s path’s size is greater than 1
// and url’s path[0] is the empty string,
// validation error, remove the first item from url’s path.
Expand Down
3 changes: 0 additions & 3 deletions url/tests/expected_failures.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,6 @@
<non-spec:/.//p> set hostname to <>
<foo:///some/path> set pathname to <>
<file:///var/log/system.log> set href to <http://0300.168.0xF0>
<file://monkey/> set pathname to <\\\\>
<file:///unicorn> set pathname to <//\\/>
<file:///unicorn> set pathname to <//monkey/..//>
<non-spec:/> set pathname to </.//p>
<non-spec:/> set pathname to </..//p>
<non-spec:/> set pathname to <//p>
Expand Down