Bug 149718 - Writer Crashes on inserting a Chart based on a Table with merged cells
Summary: Writer Crashes on inserting a Chart based on a Table with merged cells
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: x86-64 (AMD64) All
: medium major
Assignee: Hossein
URL:
Whiteboard: target:7.5.0 target:7.4.3
Keywords: haveBacktrace
: 128798 (view as bug list)
Depends on:
Blocks: Chart Crash
  Show dependency treegraph
 
Reported: 2022-06-24 18:20 UTC by inozemcew
Modified: 2024-02-26 04:18 UTC (History)
6 users (show)

See Also:
Crash report or crash signature: ["MsLangId::getScriptType(o3tl::strong_int<unsigned short,LanguageTypeTag>)"]


Attachments
File to reproduce crash (10.59 KB, application/vnd.oasis.opendocument.text)
2022-06-24 19:13 UTC, inozemcew
Details
bt with debug symbols (10.93 KB, text/plain)
2022-06-25 10:52 UTC, Julien Nabet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description inozemcew 2022-06-24 18:20:53 UTC
Description:
Writer crashes when a chart is being inserted which is based on a table with merged cells. After recovery there are an empty chart with no data source.

Steps to Reproduce:
1.Insert a table and merge two first cells
2.Put any data in other(non-merged) cells
3.Select the cells with data and click in the main menu 'Insert' - 'Chart'

Actual Results:
Writer immediately crash.

Expected Results:
Chart configuration dialog must appear.


Reproducible: Always


User Profile Reset: Yes


OpenGL enabled: Yes

Additional Info:
Version: 7.3.4.2 / LibreOffice Community
Build ID: 30(Build:2)
CPU threads: 3; OS: Linux 5.14; UI render: default; VCL: kf5 (cairo+xcb)
Locale: uk-UA (ru_UA.UTF-8); UI: ru-RU
Calc: threaded
Comment 1 Rafael Lima 2022-06-24 18:28:37 UTC
Not repro in

Version: 7.3.3.2 / LibreOffice Community
Build ID: 30(Build:2)
CPU threads: 16; OS: Linux 5.13; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Ubuntu package version: 1:7.3.3~rc2-0ubuntu0.21.10.1~lo1
Calc: threaded

Nor in

Version: 7.5.0.0.alpha0+ / LibreOffice Community
Build ID: cb83063cc0eb4e93bd44bc0cb9b7c4841230cdef
CPU threads: 16; OS: Linux 5.13; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Calc: threaded

Please, share a sample file so we can test if this is indeed a bug.
Comment 2 inozemcew 2022-06-24 19:13:09 UTC
Created attachment 180951 [details]
File to reproduce crash

Select column with numbers then 'Insert' - 'Chart' causes a crash.

The problem appears when the count of merged cells plus selected column number is greater than total count of columns, I think.
Comment 3 QA Administrators 2022-06-25 03:39:16 UTC Comment hidden (obsolete)
Comment 4 Telesto 2022-06-25 09:46:16 UTC
Confirm
Version: 7.4.0.0.alpha1+ (x64) / LibreOffice Community
Build ID: 089c91b1ad16232f130cb50266732509f83c52eb
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win
Locale: en-US (nl_NL); UI: en-GB
Calc: CL Jumbo

Also with
4.4.7.2

and 3.3.0
Comment 5 Julien Nabet 2022-06-25 10:52:24 UTC
Created attachment 180959 [details]
bt with debug symbols

On pc Debian x86-64 with master sources updated today, I could reproduce this.

I used "catch throw" to retrieve the bt.
(the right bt was after 44 throws! It seems the use of C++ exceptions in LO is  we may expect...)
Comment 6 Hossein 2022-09-16 19:54:11 UTC
Note: You have to select more than 1 cell with data (For example, all the cells that contain numbers 1 to 5), and then choose "Insert" > "Chart" to reproduce the crash.

Not reproducible with: OOo 3.2

OpenOffice.org 3.2.1 (Build:9502)
https://ftp5.gwdg.de/pub/openoffice/archive/stable/3.2.1/


Reproduced with LO 3.5

LibreOffice 3.5.0rc3 
Build ID: 7e68ba2-a744ebf-1f241b7-c506db1-7d53735
https://downloadarchive.documentfoundation.org/libreoffice/old/3.5.0.3/
It crashes after a small delay, giving this message:
terminate called after throwing an instance of 'com::sun::star::lang::IllegalArgumentException'


Reproduced with LO 7.2:

Version: 7.2.4.1 / LibreOffice Community
Build ID: 27d75539669ac387bb498e35313b970b7fe9c4f9
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded


Also with the latest LO 7.5 dev master:

Version: 7.5.0.0.alpha0+ / LibreOffice Community
Build ID: 164a1f4c3315fc44161128d3d9ca886f767f7d30
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded
Comment 7 Commit Notification 2022-10-10 16:28:07 UTC
Hossein committed a patch related to this issue.
It has been pushed to "master":

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

tdf#149718 Fix crash on insert chart for tables with merged cells

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 Commit Notification 2022-10-19 06:34:01 UTC
Hossein committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

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

tdf#149718 Fix crash on insert chart for tables with merged cells

It will be available in 7.4.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 9 Stéphane Guillou (stragu) 2024-02-26 04:17:35 UTC
*** Bug 128798 has been marked as a duplicate of this bug. ***