Apache OpenOffice (AOO) Bugzilla – Issue 68293
URL argument in loadComponentFrom URL has become case sensitive
Last modified: 2013-02-24 21:09:28 UTC
In version 2.0.3 (may be older 2.0 versions also) the "file" part in an URL is now case sensitive. It was not case sensitive in version 1.1.5. Example: ' this will load the document sUrl = "file:///C:/Docs%20OpenOffice/_cible.ods" ' this will throw exception sUrl = "File:///C:/Docs%20OpenOffice/_cible.ods" ' this will throw exception sUrl = "FILE:///C:/Docs%20OpenOffice/_cible.ods" This gives exception with macros working with versions 1.1.x.
jsc -> as: can you please take care of this issue becasue it's obivous that it is broken
AS->HRO: The method os_getSystemPathFromFileURL() must compare the URL schema case insensitive. See "RFC1738 2.1. The main parts of URLs" ... even if they say "... should treat ..." .-)
It appears that what is needed to fix this is to change the various occurences of rtl_ustr_ascii_shortenedCompare_WithLength with rtl_ustr_ascii_shortenedCompareIgnoreAsciiCase_WithLength in the body of _osl_getSystemPathFromFileURL in sal/osl/w32/file.cxx:1.11 (both the scheme "file" and the authority "localhost" have to be treated case insenstive).
Fixed. The simplest way to verify is to execute a Basic macro like Sub Main dim args() as new com.sun.star.beans.PropertyValue StarDesktop.loadComponentFromURL("File:///d:/test.odt", "_blank", 0, args) End Sub (where the File-URL must point to an existing odt file, of course). This issue is specific to Windows.
@jsk: Please verify.
Verified
looks ok. Closing