https://bugs.documentfoundation.org/show_bug.cgi?id=96413

Mike Kaganski <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |NOTABUG
             Status|NEW                         |RESOLVED

--- Comment #19 from Mike Kaganski <[email protected]> ---
(In reply to Andreas Säger from comment #0)
> Fail: ConvertToURL("C:\Foo&Bar") --> file:///C:/Foo&Bar
> Expected: ConvertToURL("C:\Foo&Bar") --> file:///C:/Foo%26Bar

This is an incorrect expectation. The URL is not required to percent-encode
every non-alphanumeric character. This character - as well as the rest listed
in the "Problem occurs with characters" - is OK in the URL unchanged. Not
percent-encoding it is OK.

> Reference:
> https://tools.ietf.org/html/rfc3986#page-12

The reference describes *how* to percent-encode octets, and also *when*; and
the latter is phrased "when that octet's corresponding character is outside the
allowed set or is being used as a delimiter of, or within, the component". And
this is exactly why the characters discussed in the comment 0 are OK in file
URL.

(In reply to Andreas Säger from comment #6)
> One of my Basic macros truncated valid file paths when I was
> assuming that function convertToURL is able to deal with valid paths like
> C:/foo & bar/document.odt

So the bug is somewhere in the said macro. It likely has some incorrect
assumptions about URL syntax.

Closing NOTABUG.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to