Bug 127652 - After deleting some text the LibreOffice Writer crash
Summary: After deleting some text the LibreOffice Writer crash
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
6.3.0.0.alpha0+
Hardware: All All
: high major
Assignee: Michael Stahl (allotropia)
URL:
Whiteboard: target:6.4.0 target:6.3.3 target:6.2....
Keywords: bibisected, bisected, regression
Depends on:
Blocks: redlinehide-regressions
  Show dependency treegraph
 
Reported: 2019-09-20 05:13 UTC by BogdanB
Modified: 2020-11-19 11:09 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
video showing the bug (908.01 KB, video/mp4)
2019-09-20 05:14 UTC, BogdanB
Details
this is the file with the text (26.33 KB, application/vnd.oasis.opendocument.text)
2019-09-20 05:15 UTC, BogdanB
Details

Note You need to log in before you can comment on or make changes to this bug.
Description BogdanB 2019-09-20 05:13:38 UTC
Description:
See the video to see what happened.
Having a new document with 4 pages with simple text. Trying to delete something like half a page of text. LibreOffice crash


Steps to Reproduce:
1.Having a new document with 4 pages with simple text. 
2. Trying to delete something like half a page of text. 
3. LibreOffice crash

Actual Results:
LibreOffice crash

Expected Results:
the text si deleted


Reproducible: Always


User Profile Reset: Yes



Additional Info:
Version: 6.3.1.2
Build ID: b79626edf0065ac373bd1df5c28bd630b4424273
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ro-RO (ro_RO.UTF-8); UI-Language: en-US
Calc: threaded

reseting user profile with Factory Reset didnt helped
Comment 1 BogdanB 2019-09-20 05:14:11 UTC
Created attachment 154307 [details]
video showing the bug

video showing the bug
Comment 2 BogdanB 2019-09-20 05:15:55 UTC
Created attachment 154308 [details]
this is the file with the text

the file with the text
Comment 3 Timur 2019-09-20 08:28:42 UTC
No repro older LO 6.0 and 6.2.0. 
Reproduced crash with 6.3.0 in Windows. So Hardware is All. Regression. No Crash report.
With 6.4+ behavior is different, text first cannot be deleted and after a while there's a message "bad array new length".
Comment 4 Xisco Faulí 2019-09-20 09:22:56 UTC
I can also reproduce it in

Version: 6.4.0.0.alpha0+
Build ID: 938d304f0f28962594853a8db1cc574abff8dc49
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US
Calc: threaded

Steps:
1. Delete content as displayed on the video
2. Undo
3. Repeat steps 1 and 2 a few times...

-> Crash
Comment 5 Xisco Faulí 2019-09-20 09:25:04 UTC
Regression introduced by:

https://cgit.freedesktop.org/libreoffice/core/commit/?id=0acde7514e666fc04805fd36503bd174162336ca

author	Michael Stahl <Michael.Stahl@cib.de>	2019-01-21 12:30:20 +0100
committer	Michael Stahl <Michael.Stahl@cib.de>	2019-01-21 14:53:29 +0100
commit 0acde7514e666fc04805fd36503bd174162336ca (patch)
tree 6a0f1d2cd4963cff538127076621ee8c171637ea
parent 1b1999009962b9d79858139bd7573947f78e6669 (diff)
sw_redlinehide: fix assert caused by buggy lcl_ModifyOfst

Bisected with: bibisect-linux64-6.3

Adding Cc: to Michael Stahl
Comment 6 Commit Notification 2019-09-24 08:15:59 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/9ec2c77046901fdacca77753052b54c81e6bc82c

tdf#127652 sw_redlinehide: don't set invalid SwTextFrame offsets

It will be available in 6.4.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Michael Stahl (allotropia) 2019-09-24 08:22:55 UTC
it looks like my fix for 124722 wasn't quite right, we set a Ofst on the last frame that's smaller than the end of the previous frame...
Comment 8 Xisco Faulí 2019-09-25 10:09:17 UTC
Verified in

Version: 6.4.0.0.alpha0+
Build ID: cc65651a0490383f1a833bb6215d8ec4272d8b5d
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US
Calc: threaded

@Michael Stahl, thanks for fixing this issue!!
Comment 9 Commit Notification 2019-09-25 10:14:54 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-6-3":

https://git.libreoffice.org/core/commit/b2369e031cbf4a370721c9ee45a33001966a6afa

tdf#127652 sw_redlinehide: don't set invalid SwTextFrame offsets

It will be available in 6.3.3.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 10 Commit Notification 2019-09-25 10:15:04 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-6-2":

https://git.libreoffice.org/core/commit/d173599d0b4667d44aa31991ccb917b1d141412e

tdf#127652 sw_redlinehide: don't set invalid SwTextFrame offsets

It will be available in 6.2.8.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 11 artur 2019-11-28 08:11:47 UTC
UItest in https://gerrit.libreoffice.org/#/c/83963/
Comment 12 Commit Notification 2019-12-06 21:28:43 UTC
Artur Neumann committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/06e45d45877349417000def82c20eaae4bfc3ee3

UI test for tdf#127652

It will be available in 6.5.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 13 Commit Notification 2020-07-16 11:59:50 UTC
Ilmari Lauhakangas committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/72186f02c118e9f5602e15c2bac9b3ac19987f93

tdf#127652: move UItest to CppunitTest

It will be available in 7.1.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.