[Libreoffice-commits] core.git: Branch 'aoo/trunk' - 2 commits - basic/source sc/source

Damjan Jovanovic damjan at apache.org
Tue Nov 3 12:08:21 PST 2015


 basic/source/runtime/iosys.cxx |    2 +-
 sc/source/core/data/table6.cxx |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 72b2f07ccac7578ef36fc2b92dcba49abe397ebc
Author: Damjan Jovanovic <damjan at apache.org>
Date:   Tue Nov 3 19:09:04 2015 +0000

    #i61277# Basic open file with random access erases all data.
    
    StarBasic tries to emulate truncation of files opened for writing
    by deleting them before opening them (if they exist). However there
    are exclusion to the truncation behaviour when the file is opened
    in append mode or is a binary file. Another exclusion - that was
    missing with disasterous consequences - is that the file should
    not be truncated when opened in random access mode.

diff --git a/basic/source/runtime/iosys.cxx b/basic/source/runtime/iosys.cxx
index 70c2438..f404c2a 100644
--- a/basic/source/runtime/iosys.cxx
+++ b/basic/source/runtime/iosys.cxx
@@ -665,7 +665,7 @@ SbError SbiStream::Open
                 {
 
                 // #??? For write access delete file if it already exists (not for appending)
-                if( (nStrmMode & STREAM_WRITE) != 0 && !IsAppend() && !IsBinary() &&
+                if( (nStrmMode & STREAM_WRITE) != 0 && !IsAppend() && !IsBinary() && !IsRandom() &&
                     xSFI->exists( aNameStr ) && !xSFI->isFolder( aNameStr ) )
                 {
                     xSFI->kill( aNameStr );
commit 72581356c8c6443e05843b3292504049de347885
Author: Damjan Jovanovic <damjan at apache.org>
Date:   Tue Nov 3 18:44:21 2015 +0000

    #i60307# search for strings in date formats fails.
    
    When "Search in" is set to "Values", search the formatted values
    instead of just the raw input. This fixes a 9 year old
    bug that's been duplicated at least 6 times, and matches what Excel
    does. Tests show even "Replace" works, and works well: if
    "October" is replaced by "November", it converts the original
    month from 10 to 11; it only converts the cell type to text if the
    resulting text is no longer a valid date. Also added BVT tests
    for the expected behaviour.

diff --git a/sc/source/core/data/table6.cxx b/sc/source/core/data/table6.cxx
index f9e229f..cb5c65b 100644
--- a/sc/source/core/data/table6.cxx
+++ b/sc/source/core/data/table6.cxx
@@ -91,7 +91,7 @@ sal_Bool ScTable::SearchCell(const SvxSearchItem& rSearchItem, SCCOL nCol, SCROW
                     bMultiLine = lcl_GetTextWithBreaks(
                         *(const ScEditCell*)pCell, pDocument, aString );
                 else
-                    aCol[nCol].GetInputString( nRow, aString );
+                    aCol[nCol].GetString( nRow, aString );
                 break;
             case SVX_SEARCHIN_NOTE:
                 {


More information about the Libreoffice-commits mailing list