Bug 46825 - calc crashes when trying to copy a chart
Summary: calc crashes when trying to copy a chart
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
3.5.0 release
Hardware: x86 (IA32) Linux (All)
: medium critical
Assignee: Markus Mohrhard
URL:
Whiteboard: target:3.6.0 target:3.5.1
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-01 06:31 UTC by Björn Michaelsen
Modified: 2012-03-05 04:16 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
test document (193.19 KB, application/vnd.oasis.opendocument.spreadsheet)
2012-03-01 06:31 UTC, Björn Michaelsen
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Björn Michaelsen 2012-03-01 06:31:09 UTC
Created attachment 57863 [details]
test document

1) lsb_release -rd
Description: Ubuntu precise (development branch)
Release: 12.04

2) apt-cache policy libreoffice-calc
libreoffice-calc:
  Installed: 1:3.5.0-1ubuntu4
  Candidate: 1:3.5.0-1ubuntu4

3) What is expected to happen in Calc via the Terminal:

cd ~/Desktop && wget -c https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/942005/+attachment/2788084/+files/Tableaux%20OK.ods -O example.ods && localc --nologo example.ods

copy ( ctrl + C ) the chart named "Produit de sortie AC" in the first sheet and Calc does not crash.

4) What happens instead is it crashes consistently.

Original Reporter Comments: this file comes from Excel and I created charts with Calc.
Comment 1 Markus Mohrhard 2012-03-02 15:02:15 UTC
This is a strange lifetime problem in the shared import/export code and happens somewhere in the process where we move the chart to the copy/paste document.

I'm inspecting it a bit more.
Comment 2 Markus Mohrhard 2012-03-02 15:59:48 UTC
Yeah, another problem introduced by the half finished chart cws from Ingrid Halama.

SchXMLCell contained a pointer to a uno::Sequence but since the copy constructor of uno::Sequence does only a flat copy you should never create instances with new/delete.

Fixed in master and send for review to the ML.
Comment 3 Not Assigned 2012-03-02 16:06:06 UTC
Markus Mohrhard committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=8f2d3c47ad40039a842fa09d98137155dcfdfe9e

don't create uno::Sequence with new, fdo#46825
Comment 4 Not Assigned 2012-03-02 19:16:57 UTC
Markus Mohrhard committed a patch related to this issue.
It has been pushed to "libreoffice-3-5":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=61600b62068bf7837c532c8b32377984ee76af1e&g=libreoffice-3-5

don't create uno::Sequence with new, fdo#46825


It will be available in LibreOffice 3.5.2.
Comment 5 Not Assigned 2012-03-05 04:16:09 UTC
Markus Mohrhard committed a patch related to this issue.
It has been pushed to "libreoffice-3-5-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=7f1f734113cc443caa2be4fbe376ab85d09eefac&g=libreoffice-3-5-1

don't create uno::Sequence with new, fdo#46825


It will be available already in LibreOffice 3.5.1.