Bug 76137 - FILEOPEN: Crash opening/viewing a sheet
Summary: FILEOPEN: Crash opening/viewing a sheet
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
4.1.5.3 release
Hardware: All Linux (All)
: high major
Assignee: Not Assigned
URL:
Whiteboard: BSA
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-13 18:48 UTC by higuita
Modified: 2015-04-19 16:54 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
gdb trace of the crash (12.48 KB, text/x-log)
2014-03-13 18:48 UTC, higuita
Details
test-case as ODS (223.43 KB, application/vnd.oasis.opendocument.spreadsheet)
2014-03-24 12:40 UTC, higuita
Details
test-case as XLS (790.50 KB, application/vnd.ms-excel)
2014-03-24 12:46 UTC, higuita
Details
Another XLS that crashes Libre Office (5.97 KB, application/vnd.ms-excel)
2014-09-01 00:44 UTC, Hugo Corbucci
Details

Note You need to log in before you can comment on or make changes to this bug.
Description higuita 2014-03-13 18:48:44 UTC
Created attachment 95737 [details]
gdb trace of the crash

I was given a big xlsx file that opens fine in MS Office. When trying to open in libreoffice it crash. I can reproduce the crash and i'm attaching the trace file.
The crash appends only after the progress bar reach the end

I can send the xlsx file to someone, but as it contains some sensitive info, i prefer not upload it to the public.

I also tried to open in openoffice 4.0.0... and it opens the file, but takes about 8 minutes to open it. Saving next to odt i could use the file.

I could also reproduce this in a friends libreoffice on opensuse (i don't know the version used)
Operating System: Debian
Version: 4.1.5.3 release
Comment 1 tommy27 2014-03-15 16:53:58 UTC
(In reply to comment #0)
> ....
> 
> I can send the xlsx file to someone, but as it contains some sensitive info,
> i prefer not upload it to the public.
> 
> ...

you can clear sensitive information by simply replacing all letters with "x, y, z"

the trace is useful but if would be better to have the test file as well
Comment 2 higuita 2014-03-18 17:13:43 UTC
The problem is that i can't open the file! :) 

i don't have windows, libreoffice crash and openoffice takes ages to open and i don't know if it will save the file and still crash... i also don't have it installed.

I will try to grab for a few minutes a windows machine to edit the file, but as the file is BIG, with many sheets, i hope i don't miss any of the important info.
Comment 3 higuita 2014-03-18 19:30:58 UTC
sorry but if i try to save the file on a excel 2013, libreoffice will not crash with the new saved file.

It should change something on the xlsx that fixs or hide the problem. 
I don't know in what version of excel the file was saved, but i can confirm that i have several versions of the file and all of then crash.

the unix file command reports this: /tmp/2.xlsx: Microsoft Excel 2007+
Comment 4 tommy27 2014-03-20 05:23:19 UTC
Ok. I change status to NEEDINFO.
unless we have a test file we cannot help.
feel free to set back to UNCONFIRMED once you can upload something we could work on it.
Comment 5 higuita 2014-03-24 12:40:34 UTC
Created attachment 96286 [details]
test-case as ODS

Ok, using openoffice i could save the file as xls and it still crash. I was lucky that the sheets with more info where not required for the crash, so i could remove then and cut the open and save time  on openoffice from ~10min to just 10s.

So after removing about 40 sheets, i'm left with 3. Those sheets don't have sensitive info, but as some find&replace didn't change the crash, i'm uploading the file with the content obfuscated any way.

I'm uploading both a xls and ods, saved by openoffice 4.0.1. Libreoffice crash opening the file, or if saved on a different sheet, it manage to open the time, but crash when we try to view the last sheet.

(by the way, the xls is a lot faster opening than the ods)
Comment 6 higuita 2014-03-24 12:46:00 UTC
Created attachment 96287 [details]
test-case as XLS
Comment 7 higuita 2014-03-24 12:49:10 UTC
i'm not creating a xlsx, as openoffice is unable to save then, but this crash also don't seem related to the file format, so i'm correcting the title to a better description
Comment 8 Joel Madero 2014-05-01 04:11:45 UTC
Thank you for reporting this issue! I have been able to confirm the issue on:
Version: 4.3.0.0.alpha0
Date:   Thu Apr 24 21:43:16 2014 +0300
Platform :Ubuntu 14.04
DE: GNOME3

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
As I've been able to confirm this problem I am marking as:

New (confirmed)
Major - freeze
High - freeze with a file which presumably opens fine in Microsoft Office and open office



+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
LibreOffice is powered by a team of volunteers, every bug is confirmed (triaged) by human beings who mostly give their time for free. We invite you to join our triaging by checking out this link:
https://wiki.documentfoundation.org/QA/BugTriage and join us on freenode at #libreoffice-qa

There are also other ways to get involved including with marketing, UX, documentation, and of course developing -  http://www.libreoffice.org/get-help/mailing-lists/. 

Lastly, good bug reports help tremendously in making the process go smoother, please always provide reproducible steps (even if it seems easy) and attach any and all relevant material
Comment 9 Kohei Yoshida 2014-05-02 21:29:18 UTC
Hmm. I can open both the ods and xls files using the master build on Linux.
Comment 10 Kohei Yoshida 2014-05-02 21:31:35 UTC
But does crash when opening either one of them with 4.1.
Comment 11 tommy27 2014-05-02 21:46:12 UTC
I can open both files in 4.2.3.3 under Win7x64
the ods is much slower (a couple of minutes) to load than the xls (a few seconds)

same results in 4.3.0.0.alpha1+
Build ID: 0b03f7ed575838f90e6b1ebec3538a3a214f81fb
TinderBox: Win-x86@42, Branch:master, Time: 2014-04-30_02:30:23

so it WORKSFORME under Windows
Comment 12 Hugo Corbucci 2014-09-01 00:44:20 UTC
Created attachment 105526 [details]
Another XLS that crashes Libre Office

This is a file generated following instructions on http://railscasts.com/episodes/362-exporting-csv-and-excel?view=asciicast.

In this case, I narrowed down the issue to being the range of a condition value:
    <ConditionalFormatting xmlns="urn:schemas-microsoft-com:office:excel">
      <Range>R2C1:R1C16384</Range>
      <Condition>
        <Value1>MOD(SUBTOTAL(3,'Final Reviews'!R2C1:R[2]C1),6)&lt;3</Value1>
        <Format Style='background:silver'/>
      </Condition>
    </ConditionalFormatting>

The range is apparently too big for LibreOffice and causes a crash.
I've found that if the range is R1C1893, LibreOffice crashes.
If the range is R1C1892, LibreOffice manages to open the file perfectly.

Certainly an issue with memory allocation but I know very little of where this would be in the code to help further.
Comment 13 Julien Nabet 2015-04-19 10:27:50 UTC
On pc Debian x86-64 with master sources updated today or with LO Debian package 4.3.3, I don't reproduce the crash with any of the 3 files.

Higuita: could you give a try to recent LO version (4.4.2 or at least 4.3.6)?
Comment 14 higuita 2015-04-19 16:36:02 UTC
With libreoffice 4.4.1.2 i also don't get any crash with any of the 3 files. 

Seeing this i think that this bug can be closed, libreoffice have improved a lot this years, so looks like it was fixed somewhere.

Thanks!
Comment 15 Julien Nabet 2015-04-19 16:54:09 UTC
Thank you for your feedback.
Just nitpicking but since there's no specific fix, let's put WFM instead.