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

            Bug ID: 98705
           Summary: Reduce Windows starting time by removing
                    GetCaseCorrectPathName usage
           Product: LibreOffice
           Version: unspecified
          Hardware: All
                OS: Windows (All)
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: framework
          Assignee: [email protected]
          Reporter: [email protected]

GetCaseCorrectPathName is a slow and likely obsolete function, mostly removed
from the code.
Removing temporarily its last occurance (by the following test patch) resulted
~10% speed up in LO starting time on Windows.
So it would be fine to remove (or replace it GetLongPathName or something
relevant, if needed) finally.

--- a/sal/osl/w32/file_dirvol.cxx
+++ b/sal/osl/w32/file_dirvol.cxx
@@ -1666,7 +1666,7 @@ oslFileError SAL_CALL osl_getFileStatus(

     if ( uFieldMask & osl_FileStatus_Mask_FileURL )
     {
-        if ( !pItemImpl->bFullPathNormalized )
+        if ( 0 && !pItemImpl->bFullPathNormalized )
         {
             ::osl::LongPathBuffer< sal_Unicode > aBuffer( MAX_LONG_PATH );
             sal_uInt32 nNewLen = GetCaseCorrectPathName( rtl_uString_getStr(
pItemImpl->m_pFullPath ),

Some information in sal/osl/w32/file_url.cxx:

// Same as GetLongPathName but also 95/NT4
static DWORD GetCaseCorrectPathNameEx(
    LPWSTR  lpszPath,   // path buffer to convert
    DWORD   cchBuffer,      // size of path buffer
    DWORD   nSkipLevels,
    BOOL bCheckExistence )

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to