Bug 106868 - Calc crashes to modify external link
Summary: Calc crashes to modify external link
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
5.2.0.0.alpha1
Hardware: All All
: highest critical
Assignee: Not Assigned
URL:
Whiteboard: target:5.4.0 target:5.3.3
Keywords: haveBacktrace, notBibisectable, regression
Depends on:
Blocks:
 
Reported: 2017-03-30 09:18 UTC by Nicola Ricciarelli
Modified: 2017-07-10 15:38 UTC (History)
4 users (show)

See Also:
Crash report or crash signature: ["Dialog::EndDialog(long)"]


Attachments
wrong attachment, sorry! (7.11 KB, application/vnd.oasis.opendocument.spreadsheet)
2017-03-30 09:18 UTC, Nicola Ricciarelli
Details
this is the good test document (8.79 KB, application/vnd.oasis.opendocument.spreadsheet)
2017-03-31 09:20 UTC, Nicola Ricciarelli
Details
gdb backtrace (32.99 KB, text/x-log)
2017-03-31 11:06 UTC, Xisco Faulí
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nicola Ricciarelli 2017-03-30 09:18:23 UTC
Created attachment 132276 [details]
wrong attachment, sorry!

If I've a calc document containing an external link and I try to modify it (because I selected the wrong Table/Range), when I select the new one and press OK ... libreoffice crashes.

Thanks,

Nicola
Comment 1 Xisco Faulí 2017-03-30 09:53:52 UTC Comment hidden (obsolete)
Comment 2 m_a_riosv 2017-03-30 21:11:55 UTC
There are no links on the file.
Comment 3 Nicola Ricciarelli 2017-03-31 09:20:51 UTC
Created attachment 132295 [details]
this is the good test document
Comment 4 Nicola Ricciarelli 2017-03-31 09:39:57 UTC
OH, yes, sorry, bot of you are right: while preparing an example spreadsheed document to furnish you, I attached the wrong one. (I must buy some glasses! eheh)

1) Go in Edit and select Links
2) Select the unique external link present and click on "Modify"
3) Choose one of the options available in "Available Tables/Ranges"
4) When you click on "OK" .. it immediately crashes!

1) Go in Edit and select Links
2) Select the unique external link present and click on "Modify"
3) If you decide to do nothing and click "Cancel" ... it crashes!   (I've just noticed it)


That external link is just an example: the same problem happens with lots other websites links I've tested.
As there's no preview of the datas that are going to inserted, if you chosed the wrong one you've to change another HTML_x, unless you find the one containing the infos you need.


I've attached the correct one (prova.ods).
Sorry guys!

Nicola
Comment 5 Xisco Faulí 2017-03-31 10:58:18 UTC
Confirmed in

Version: 5.4.0.0.alpha0+
Build ID: 6152bf9ee9b2e348dee854921a5a5db1cfc72995
CPU threads: 4; OS: Linux 4.8; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: group

but not in

Version: 5.2.0.0.alpha1+
Build ID: 5b168b3fa568e48e795234dc5fa454bf24c9805e
CPU Threads: 4; OS Version: Linux 4.8; UI Render: default; 
Locale: ca-ES (ca_ES.UTF-8)

I can't bisect it because Link dialog started crashing after 

author	Noel Grandin <noel@peralex.com>	2016-09-21 12:48:15 (GMT)
committer	Noel Grandin <noel.grandin@collabora.co.uk>	2016-10-27 06:08:30 (GMT)
commit eca5ea9f79181d45cd7fbabe2313617d3025818a (patch)
tree 10b5837fe04212349825742b38f5a37be9ce7009
parent bbd44f8f89839b5abb4ec6c7ea195431de5b2f48 (diff)
make the AbstractDialog stuff extend from VclReferenceBase

and once it was fixed by

author	Takeshi Abe <tabe@fixedpoint.jp>	2016-11-10 00:36:12 (GMT)
committer	Noel Grandin <noel.grandin@collabora.co.uk>	2016-11-10 10:51:59 (GMT)
commit c024344c2fe3d40050fa7144935704f16adec6e9 (patch)
tree 491607124bc0199509c11f7105c8425839eda3cc
parent 25edea06374e5283f28c3ea9a29c470c575f3364 (diff)
Wrap pointer to dialog with VclPtr

this bug already crashes.
I guess it might be related to VclPtr and VclReferences, so

Adding Cc: to Noel Grandin
Comment 6 Xisco Faulí 2017-03-31 11:06:39 UTC
Created attachment 132296 [details]
gdb backtrace
Comment 7 Julien Nabet 2017-03-31 23:13:32 UTC
I submitted a patch to review here for master sources:
https://gerrit.libreoffice.org/#/c/35987/
Comment 8 Julien Nabet 2017-04-04 14:04:59 UTC
Unassign myself since my patch is wrong.
Comment 9 Commit Notification 2017-04-05 06:40:01 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "master":

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

tdf#106868: fix crash when modify external link

It will be available in 5.4.0.

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

Affected users are encouraged to test the fix and report feedback.
Comment 10 Xisco Faulí 2017-04-05 15:50:43 UTC
Hi Noel,
Thanks for fixing this.
Can it be backported to 5.3 branch?
Regards
Comment 11 Nicola Ricciarelli 2017-04-05 16:05:58 UTC
> 
> Affected users are encouraged to test the fix and report feedback.
>

Noel, thanks ... I'll await 1-2 days and I'll test if everything is ok.
I agree with Xisco suggestion, if it'll be "compatible" with releases timings.

Nicola
Comment 12 Commit Notification 2017-04-06 07:05:04 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "libreoffice-5-3":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=16e2701d02e777673c957ff77bcc0a66e24f9d81&h=libreoffice-5-3

tdf#106868: fix crash when modify external link

It will be available in 5.3.3.

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

Affected users are encouraged to test the fix and report feedback.
Comment 13 Nicola Ricciarelli 2017-04-06 07:16:29 UTC
Hi Noel,
As you asked for, I've just downloaded and tested the following versions:
libo-master64~2017-04-06_01.51.07_LibreOfficeDev_5.4.0.0.alpha0_Win_x64
master~2017-04-06_00.40.42_LibreOfficeDev_5.4.0.0.alpha0_Linux_x86-64
(sorry, I've no Mac)

Now everything is working perfectly.
I've done some tests: modify the "good" prova document I attached, added new external links, modify them. For all tests, no crashes.

Nicola
Comment 14 Noel Grandin 2017-04-06 07:26:10 UTC
thank you very much for testing Nicola