Bug 147466 - Crash swlo!SwDoc::InvalidateNumRules+0x657 (track changes involved)
Summary: Crash swlo!SwDoc::InvalidateNumRules+0x657 (track changes involved)
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.3.0.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:7.5.0 target:7.4.1 target:7.3.6
Keywords: bibisected, bisected, haveBacktrace, regression
Depends on:
Blocks: Track-Changes Crash
  Show dependency treegraph
 
Reported: 2022-02-16 15:02 UTC by Telesto
Modified: 2022-08-18 08:56 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
Example file (80.73 KB, application/vnd.oasis.opendocument.text)
2022-02-16 15:02 UTC, Telesto
Details
Screencast (1.93 MB, video/mp4)
2022-02-16 15:03 UTC, Telesto
Details
bt with debug symbols (2.50 KB, text/plain)
2022-02-16 19:04 UTC, Julien Nabet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Telesto 2022-02-16 15:02:15 UTC
Description:
Crash swlo!SwDoc::InvalidateNumRules+0x657

Steps to Reproduce:
1. open the attached file (modified version of attachment 163638 [details]
2. Place cursor at the end of yellow marked area (so after Korean)
3. Press Shift+CTRL+ARROW UP 6x (whole yellow marked area selected)
4. Press backspace 5x
5. Edit -> Track Changes -> Manage
6. Reject 5 times -> Crash

Actual Results:
Crash

Expected Results:
No crash


Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 7.4.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 2bb10a827ac13d0caf009e8526ccd9f17dc71653
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win
Locale: nl-NL (nl_NL); UI: en-US
Calc: CL
Comment 1 Telesto 2022-02-16 15:02:34 UTC
Created attachment 178311 [details]
Example file
Comment 2 Telesto 2022-02-16 15:03:22 UTC
Created attachment 178312 [details]
Screencast
Comment 3 Julien Nabet 2022-02-16 19:04:13 UTC
Created attachment 178317 [details]
bt with debug symbols

On pc Debian x86-64 with master sources updated today, I reproduced the crash. (not sure if I respected exactly the process but it crashed indeed).
Comment 4 Xisco Faulí 2022-04-18 11:54:41 UTC
Also reproduced in

Version: 7.1.0.0.alpha1+
Build ID: 738bcf5e9a8c443d60c29c3a8068e8c16c72638a
CPU threads: 8; OS: Linux 5.10; UI render: default; VCL: gtk3
Locale: es-ES (es_ES.UTF-8); UI: en-US
Calc: threaded
Comment 5 Xisco Faulí 2022-04-18 11:55:57 UTC
Not reproduced in

Version: 7.0.0.0.alpha1+
Build ID: 574c57090642347980d2395e1e183cc7b5c171ad
CPU threads: 8; OS: Linux 5.10; UI render: default; VCL: gtk3
Locale: es-ES (es_ES.UTF-8); UI: en-US
Calc: threaded
Comment 6 Gabor Kelemen (allotropia) 2022-08-11 08:33:33 UTC
I can reproduce this only in 7.3 and newer (including current master), with slightly different steps:

After marking all the yellow area with 6 Shift+Ctrl+Up, press backspace 4 times, so only 4 changes are created. Rejecting all of them then crashes.

This seems to have started in:

https://git.libreoffice.org/core/+/6433dc223f6d21570e7132c4a580d186a5d5a334

author	Michael Stahl <michael.stahl@allotropia.de>	Fri Nov 19 16:08:57 2021 +0100
committer	Thorsten Behrens <thorsten.behrens@allotropia.de>	Thu Dec 23 12:08:38 2021 +0100

Revert "Revert "sw_fieldmarkhide: init fieldmark mode from options""
Comment 7 Commit Notification 2022-08-17 12:06:16 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/7d730cd580e957ab06b0c7f020ac37dd0c337aa2

tdf#147466 sw_redlinehide: avoid crashing by delete un-deleting

It will be available in 7.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 8 Michael Stahl (allotropia) 2022-08-17 12:15:54 UTC
it looks like some conflict between code to hide redlines, and code to split up redlines on paragraph breaks: the latter causes section nodes that were previously in a redline not to be in a redline any more, and the former doesn't expect that.

the crash is hopefully fixed on master.
Comment 9 László Németh 2022-08-17 14:51:53 UTC
(In reply to Michael Stahl (allotropia) from comment #8)
> it looks like some conflict between code to hide redlines, and code to split
> up redlines on paragraph breaks: the latter causes section nodes that were
> previously in a redline not to be in a redline any more, and the former
> doesn't expect that.
> 
> the crash is hopefully fixed on master.

@Michael: many thanks for the fix and for the feedback!
Comment 10 Commit Notification 2022-08-18 08:55:32 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

https://git.libreoffice.org/core/commit/18254a36dbdb68b3b4bbbcaed0d33ba0840539a9

tdf#147466 sw_redlinehide: avoid crashing by delete un-deleting

It will be available in 7.4.1.

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 Commit Notification 2022-08-18 08:56:47 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-7-3":

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

tdf#147466 sw_redlinehide: avoid crashing by delete un-deleting

It will be available in 7.3.6.

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.