Bug 83201 - FILESAVE: Crash on save with Google finance external link
Summary: FILESAVE: Crash on save with Google finance external link
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
4.3.0.4 release
Hardware: Other All
: high critical
Assignee: Markus Mohrhard
URL:
Whiteboard: BSA
Keywords: bibisectRequest, haveBacktrace, regression
: 86351 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-08-28 15:15 UTC by testgallery24
Modified: 2015-12-17 08:34 UTC (History)
6 users (show)

See Also:
Crash report or crash signature:


Attachments
console_bt with master sources (13.24 KB, text/plain)
2014-08-28 22:16 UTC, Julien Nabet
Details
valgrind trace (34.66 KB, application/x-bzip)
2014-08-31 13:45 UTC, Julien Nabet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description testgallery24 2014-08-28 15:15:05 UTC
Problem description: 
If using Google finance external link, Calc crashes when trying to 'Save' or 'Save as...' document.

Steps to reproduce:
1. File -> New -> Spreadsheet
2. Insert -> Link to External Data
3. Enter 'http://www.google.com/finance' (and hit enter)
4. Click 'OK' in pop-up 'Import Options' window (leaving language as 'Automatic')
5. Select 'HTML_tables' in External Data window and click 'OK' (data is entered into spreadsheet OK)
6. File -> Save (crashes Calc)

Current behavior:
Calc crashes and tries to recover file.

Expected behavior:
Calc should save file successfully.
First failed in v4.3.0 and also fails in v4.3.1.
Works OK in v4.2.5 and v4.2.6.
Also works OK with other external links such as http://finance.yahoo.com.
Operating System: Windows 7
Version: 4.3.0.4 release
Last worked in: 4.2.6.2 release
Comment 1 raal 2014-08-28 17:34:33 UTC
Thank you for submitting the bug. I can confirm that the bug is present in master.

Version: 4.4.0.0.alpha0+
Build ID: 37b9ea92ba81d74764a2345a9c75c65bfd272d2b
TinderBox: Linux-rpm_deb-x86_64@46-TDF, Branch:master, Time: 2014-08-26_09:48:30
Comment 2 raal 2014-08-28 17:41:13 UTC
No problem with LO 4.2.4.2, regression
Comment 3 Julien Nabet 2014-08-28 22:16:55 UTC
Created attachment 105395 [details]
console_bt with master sources

On pc Debian x86-64 with master sources updated today, I could reproduce the crash.
Comment 4 Julien Nabet 2014-08-28 22:18:33 UTC
I also noticed these kind of logs during the process:
Throwing InvalidHeaderException
:1: parser error : xmlParseEntityRef: no name
eStamp("CSI/"+a)}catch(e){}};this.tick("start",null,a)}var a;window.performance&
                                                                               ^
warn:oox.storage:19233:1:oox/source/helper/zipstorage.cxx:66: ZipStorage::ZipStorage exception opening input storage:
Comment 5 Markus Mohrhard 2014-08-31 08:56:57 UTC
(In reply to comment #4)
> I also noticed these kind of logs during the process:
> Throwing InvalidHeaderException
> :1: parser error : xmlParseEntityRef: no name
> eStamp("CSI/"+a)}catch(e){}};this.tick("start",null,a)}var
> a;window.performance&
>                                                                             
> ^
> warn:oox.storage:19233:1:oox/source/helper/zipstorage.cxx:66:
> ZipStorage::ZipStorage exception opening input storage:

They are unrelated. Once again it is a use after free problem in the style and formatting handling.
Comment 6 Julien Nabet 2014-08-31 13:45:13 UTC
Created attachment 105486 [details]
valgrind trace

I retrieved a Valgrind trace with master sources updated today.
Hope it may help a bit.
Comment 7 Markus Mohrhard 2014-08-31 19:02:35 UTC
(In reply to comment #6)
> Created attachment 105486 [details]
> valgrind trace
> 
> I retrieved a Valgrind trace with master sources updated today.
> Hope it may help a bit.

The problem is far away from the actual crash. There is sadly nothing that tools can do to help understand the issue.

It is about a ScStyleSheet being used from the temporary copy document in the ScPatternAttr that is applied to the main document. The whole cycle of the ScStyleSheet handling looks a bit strange in the Link External Data code.
Comment 8 Joel Madero 2014-11-07 16:45:17 UTC
Markus - you don't think a bibisect would help understand this? at least find out what caused the problem?
Comment 9 raal 2014-11-16 21:45:25 UTC
*** Bug 86351 has been marked as a duplicate of this bug. ***
Comment 10 Andras Timar 2015-04-14 10:12:18 UTC
I think, it's been fixed by commit 06f85d41d02ebef76487b230f35f2ec638c46c8b
Author: Michael Stahl <mstahl@redhat.com>
Date:   Wed Dec 10 16:06:21 2014 +0100

    xmloff: make the export of the horrible field marks aware of auto-styles
Comment 11 Robinson Tryon (qubit) 2015-12-17 08:34:09 UTC
Migrating Whiteboard tags to Keywords: (bibisectRequest)
[NinjaEdit]