Bug 118445 - attempt to link documents circularly freezes writer
Summary: attempt to link documents circularly freezes writer
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
5.4.7.2 release
Hardware: All Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Section
  Show dependency treegraph
 
Reported: 2018-06-29 09:58 UTC by Yury
Modified: 2019-07-15 07:23 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Yury 2018-06-29 09:58:25 UTC
Description:
Replication:

Create and save two empty docs. In the 1st doc, insert a section and 'link' its contents to the 2nd doc. Save the 1st doc.

In the 2nd doc, 'insert' a 'section', set 'link' checkbox, set 'file name' to the 1st doc.

After clicking 'Insert', Writer freezes with maximum cpu usage.

Expected result: Writer recognises the attempt to back-link and -- this is just an idea -- blocks the 'links update' functionality for the offending content, with an informational message. But surely not use up all the resources.

Steps to Reproduce:
Create and save two empty docs. 

In the 1st doc, insert a section and 'link' its contents to the 2nd doc. Save the 1st doc.

In the 2nd doc, 'insert' a 'section', set 'link' checkbox, set 'file name' to the 1st doc.

Click 'Insert'.

Actual Results:
Writer freezes, maxing the CPU usage.

Expected Results:
Writer recognises the attempt to back-link and -- this is just an idea -- blocks the 'links update' functionality for the offending content, with an informational message. But surely not use up all the resources.


Reproducible: Always


User Profile Reset: No



Additional Info:
Comment 1 Buovjaga 2018-07-14 17:37:24 UTC
Yep, such a safety mechanism would be cool.

Arch Linux 64-bit
Version: 6.2.0.0.alpha0+
Build ID: 860a9daf2b45942a4b10ff22d36aa3fe29be19f4
CPU threads: 8; OS: Linux 4.17; UI render: default; VCL: gtk3; 
Locale: fi-FI (fi_FI.UTF-8); Calc: group threaded
Built on July 14th 2018
Comment 2 QA Administrators 2019-07-15 02:47:52 UTC Comment hidden (obsolete)
Comment 3 Yury 2019-07-15 07:23:33 UTC
Actual results now:
LO crashes on the attempt to 'insert' a section in the 2nd doc.

Version: 6.2.5.2
Build ID: 1ec314fa52f458adc18c4f025c545a4e8b22c159
CPU threads: 4; OS: Linux 4.19; UI render: default; VCL: gtk3; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-US
Calc: CL