sfx2/source/dialog/filedlghelper.cxx                   |   11 ++++++++++-
 shell/source/win32/shlxthandler/propsheets/makefile.mk |    2 +-
 2 files changed, 11 insertions(+), 2 deletions(-)

New commits:
commit dc2fe18e95731dcb7c9e2027f45fdaf265490592
Author: Michael Stahl <mst...@redhat.com>
Date:   Thu Apr 5 18:09:41 2012 +0200

    fdo#43895 lp#905355: fix the fix so it doesn't crash
    
    rtl::OUString rtl::OUString::copy(sal_Int32) const: Assertion
    `beginIndex >= 0 && beginIndex <= getLength()' failed.
    (regression from dd2fe95cce75f1157bd1c75d286a0047b2e4175e)

diff --git a/sfx2/source/dialog/filedlghelper.cxx 
b/sfx2/source/dialog/filedlghelper.cxx
index 0018912..37a2f29 100644
--- a/sfx2/source/dialog/filedlghelper.cxx
+++ b/sfx2/source/dialog/filedlghelper.cxx
@@ -1641,8 +1641,17 @@ void FileDialogHelper_Impl::getRealFilter( String& 
_rFilter ) const
 void FileDialogHelper_Impl::verifyPath()
 {
 #ifdef UNX
+    static char const s_FileScheme[] = "file://";
+    if (0 != rtl_ustr_ascii_shortenedCompareIgnoreAsciiCase_WithLength(
+                maPath.getStr(), maPath.getLength(),
+                s_FileScheme, RTL_CONSTASCII_LENGTH(s_FileScheme)))
+    {
+        return;
+    }
+    const OString sFullPath = OUStringToOString(
+            maPath.copy(RTL_CONSTASCII_LENGTH(s_FileScheme)) + maFileName,
+            osl_getThreadTextEncoding() );
     struct stat aFileStat;
-    const OString sFullPath = OUStringToOString( 
maPath.copy(RTL_CONSTASCII_LENGTH("file://")) + maFileName, 
osl_getThreadTextEncoding() );
     stat( sFullPath.getStr(), &aFileStat );
     // lp#905355, fdo#43895
     // Check that the file has read only permission and is in /tmp -- this is
commit d564c79e6d0780882845a28d8ab32f9eb3dee03b
Author: Michael Stahl <mst...@redhat.com>
Date:   Thu Apr 5 12:59:37 2012 +0200

    shell: fix silly flags from 2c5a817591

diff --git a/shell/source/win32/shlxthandler/propsheets/makefile.mk 
b/shell/source/win32/shlxthandler/propsheets/makefile.mk
index 1d67510..08adff7 100644
--- a/shell/source/win32/shlxthandler/propsheets/makefile.mk
+++ b/shell/source/win32/shlxthandler/propsheets/makefile.mk
@@ -41,7 +41,7 @@ CDEFS+=-U_WIN32_WINNT -D_WIN32_WINNT=0x0501 -U_WIN32_IE 
-D_WIN32_IE=0x501
 CFLAGS+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820
 CFLAGS_X64+=-DISOLATION_AWARE_ENABLED -DWIN32_LEAN_AND_MEAN -DXML_UNICODE 
-D_NTSDK -DUNICODE -D_UNICODE
 CFLAGS_X64+=-wd4710 -wd4711 -wd4514 -wd4619 -wd4217 -wd4820
-CDEFS_X64+=-U_WIN32_IE -D_WIN32_WINNT=0x0501 -U_WIN32_WINNT -D_WIN32_IE=0x501
+CDEFS_X64+=-U_WIN32_WINNT -D_WIN32_WINNT=0x0501 -U_WIN32_IE -D_WIN32_IE=0x501
 .ENDIF
 
 .IF "$(SYSTEM_ZLIB)" == "YES"
_______________________________________________
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to