diff options
author | Laurent Balland <laurent.balland@mailo.fr> | 2024-04-15 18:43:35 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2024-04-17 13:05:52 +0200 |
commit | 47187acee758680cda8086b6e295ef7beea3491b (patch) | |
tree | 5e53283816141d50c4c08f3021af9814a40f1cb3 /sc/source/ui | |
parent | c53b3f08776cfc64f40b4508c44bbd8424769822 (diff) |
tdf#129701 Follow-up of previous change
According to comments in https://gerrit.libreoffice.org/c/core/+/163536
Follow-up of previous change
Change-Id: Icd7b6798d6ef35ca9574125cd3d4c4d89044569c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166133
Tested-by: Jenkins
Reviewed-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'sc/source/ui')
-rw-r--r-- | sc/source/ui/docshell/impex.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sc/source/ui/docshell/impex.cxx b/sc/source/ui/docshell/impex.cxx index 248c837b6dd1..80b4a2b96701 100644 --- a/sc/source/ui/docshell/impex.cxx +++ b/sc/source/ui/docshell/impex.cxx @@ -1592,7 +1592,7 @@ bool ScImportExport::ExtText2Doc( SvStream& rStrm ) ScDocumentImport aDocImport(rDoc); do { - SCCOL nLastCol = nEndCol; // tdf#129701 preserve value of nEndCol + const SCCOL nLastCol = nEndCol; // tdf#129701 preserve value of nEndCol for( ;; ) { aLine = ReadCsvLine(rStrm, !bFixed, aSeps, cStr, cDetectSep); @@ -1714,15 +1714,15 @@ bool ScImportExport::ExtText2Doc( SvStream& rStrm ) aTransliteration, aCalendar, pEnglishTransliteration.get(), pEnglishCalendar.get()); } + ++nCol; if (bIsLastColEmpty) { bIsLastColEmpty = false; // toggle to stop } else { - ++nCol; // tdf#129701 detect if there is a last empty column when we need it - bIsLastColEmpty = !(*p) && !bSkipEmptyCells && !bDetermineRange && nCol == nLastCol; + bIsLastColEmpty = (nCol == nLastCol) && !(*p) && !bSkipEmptyCells && !bDetermineRange; } } |