Bug Hunting Session
Bug 54609 - CRASH when FILEOPEN particular .xlsx
Summary: CRASH when FILEOPEN particular .xlsx
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
3.5.2 release
Hardware: All Linux (All)
: medium major
Assignee: Not Assigned
URL:
Whiteboard: target:3.6.2 target:3.7.0
Keywords: regression
: 48366 49690 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-09-06 17:04 UTC by Per Gunnarsson
Modified: 2013-01-09 13:49 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
Account report created from a web page of my bank. (10.37 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2012-09-06 17:04 UTC, Per Gunnarsson
Details
bt + console logs on master (13.20 KB, text/plain)
2012-09-06 21:06 UTC, Julien Nabet
Details
Proposed patch (2.71 KB, patch)
2012-09-10 05:55 UTC, Muthu
Details
The Journal is generated on the corporate website (10.81 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2012-09-21 04:23 UTC, arcfi
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Per Gunnarsson 2012-09-06 17:04:10 UTC
Created attachment 66739 [details]
Account report created from a web page of my bank.

LibreOffice Calc crashes when trying to open a Excel (xlsx) file. The file was automatically created from my banks home page. En example file is attached.
Comment 1 Rainer Bielefeld Retired 2012-09-06 17:43:23 UTC
My first suspect was that this one is a DUP of "Bug 48366 - FILEOPEN for particular .xlsx impossible, "General Error"", but there we only have an Error message, not a crash

@reporter:
Thank you for your report – unfortunately important information is missing.
May be hints on <http://wiki.documentfoundation.org/BugReport> will help you to find out what information will be useful to reproduce your problem?
Please:
- Attach screenshots with comments if you believe that that might explain the 
  problem better than a text comment. Best way is to insert your screenshots
  into a DRAW document and to add comments that explain what you want to show
- Contribute a document related step by step instruction containing every 
  key press and every mouse click how to reproduce your problem 
  (similar to example in Bug 43431)
– if possible contribute an instruction how to create a sample document 
  from the scratch
- add information 
  -- what EXACTLY happens
  -- concerning your PC 
  -- concerning your OS (Version, Distribution, Language)
  -- concerning your LibO version (with Build ID if it's not a public release)
     and localization (UI language, Locale setting)
  –- Libo settings that might be related to your problems 
  -- how you launch LibO and how you opened the sample document
  –- Whether your problem persists when you renamed your user profile 
     before you launch LibO (please see
     <https://wiki.documentfoundation.org/UserProfile#User_profile_location>)
  -- everything else crossing your mind after you read linked texts
Comment 2 Julien Nabet 2012-09-06 21:06:15 UTC
Created attachment 66750 [details]
bt + console logs on master

On pc Debian x86-64 with master sources updated today, I had a crash.
I attached console + bt with symbols.
Comment 3 Julien Nabet 2012-09-06 21:08:27 UTC
Muthu: one for you?
Comment 4 Per Gunnarsson 2012-09-07 07:12:21 UTC
OK, I try to give some more background.
I have a dual boot system with Windows XP and Ubunto.
I just updated my system from Ubunto 10.04 to 12.04. (Swedish language)
Doing so the OpenOffice suite was substituted by
LibreOffice 3.5.4.2 
Build ID: 350m1(Build:2)

This is what happens when I open the xlsx file.

1. I lauch LibreOffice Calc from the launcher.
2, Then I use menu command File/Open
3. Click on the file in a folder window
4. In the LibreOffice Calc window loading procedure is indicated
5. When loading indicator reaches 100%, the LibreOffice window just closes.
6. Looking in my folder where the xlsx file is located I notice the the .~lock file is still there.

If I boot windows XP instead of Ubunto I can open the file with OpenOffice without problem.
Comment 5 Rainer Bielefeld Retired 2012-09-07 16:46:51 UTC
Reproducible with UBUNTU 12.4 64Bit / LibO 3.5.2.2. (VirtualBox). When I open sample document from LibO File menu LibO stops responding with progress bar short before end, then LibO vanishes silently.

Ubuntu 11.10 32Bit LibO 3.4.4 (VirtualBox) opens the document without crash, so it seems we have a regression.
Comment 6 Markus Mohrhard 2012-09-09 21:11:53 UTC
Ok, I debugged it and it seemss to be a problem when an exception is thrown that at some point a SIGSEGV follows. I suspect that it calls a destructor of an already destructed element leading to a double delete.
Comment 7 Muthu 2012-09-10 05:55:19 UTC
Created attachment 66900 [details]
Proposed patch

Seems like an exception is thrown by a (static) function and is not handled.
Comment 8 Muthu 2012-09-10 05:56:42 UTC
It would be nice if somebody can confirm if the fix works, please?
[fyi: I tested this with libo-master on Linux]

Thanks!
Comment 9 Julien Nabet 2012-09-12 20:47:33 UTC
(In reply to comment #8)
> It would be nice if somebody can confirm if the fix works, please?
> [fyi: I tested this with libo-master on Linux]
> 
> Thanks!
Muthu: Only Linux test of course (since I suppose you wait for MacOs and Windows test results), but on pc Debian x86-64 with master sources updated today, I don't reproduce this behaviour.
Comment 10 Markus Mohrhard 2012-09-13 01:24:35 UTC
*** Bug 54750 has been marked as a duplicate of this bug. ***
Comment 11 Markus Mohrhard 2012-09-18 06:38:39 UTC
@Muthu: Is this bug fixed in all relevant branches?
Comment 12 Kohei Yoshida 2012-09-20 15:32:38 UTC
We need to backport this fix to 3.6 to fix Bug 48366.  I'll do that in a minute with my sign-off.
Comment 13 Not Assigned 2012-09-20 15:41:18 UTC
Muthu Subramanian committed a patch related to this issue.
It has been pushed to "libreoffice-3-6":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=3ad52a6453ff612409123db29dc74a9071789aab&g=libreoffice-3-6

fdo#54609, fdo#45366: Exception while importing xlsx.


It will be available in LibreOffice 3.6.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 14 Kohei Yoshida 2012-09-20 18:21:25 UTC
*** Bug 48366 has been marked as a duplicate of this bug. ***
Comment 15 Not Assigned 2012-09-20 18:39:39 UTC
Muthu Subramanian committed a patch related to this issue.
It has been pushed to "libreoffice-3-6-2":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=9b1ba36bce25cf5abd41835d5d4c156893e8eca6&g=libreoffice-3-6-2

fdo#54609, fdo#45366: Exception while importing xlsx.


It will be available already in LibreOffice 3.6.2.

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 16 arcfi 2012-09-21 04:23:10 UTC
Created attachment 67470 [details]
The Journal is generated on the corporate website
Comment 17 Michael Meeks 2012-09-21 15:51:42 UTC
*** Bug 49690 has been marked as a duplicate of this bug. ***
Comment 18 Michael Meeks 2012-09-21 15:53:59 UTC
Marking FIXED - *but* there is a very similar bug (with a lot more detail) in bug#49819 - that shows -why- the exception is being thrown that causes this grief. Sadly that can happen for more than just this (ignoreable) properties stream - and IMHO this fix is not really correct.

The real question is: how do these documents get like that ? Why are their stream timestamps out of sync. with their directory timestamps ? it seems very odd to me.

Can someone construct a pristine document by saving in MS Office that demonstrates this ? - how did you create your report Per ?
Comment 19 Vincent 2012-09-22 04:27:06 UTC
(In reply to comment #18)
> The real question is: how do these documents get like that ? Why are their
> stream timestamps out of sync. with their directory timestamps ? it seems very
> odd to me.

Not sure if this will help, but in my case, I have created the Excel file with Excel 2010 on a Windows 7 PC, and then I let UbuntuOne sync this file with my Ubuntu laptop.
When I have tried to open the file on the Ubuntu laptop, it give me this error.
Comment 20 Not Assigned 2012-09-24 08:44:15 UTC
Fridrich Å trba committed a patch related to this issue.
It has been pushed to "libreoffice-3-6":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=da1b4e50d97123b09e56d6dfaf8458a0890e3f05&g=libreoffice-3-6

Revert "fdo#54609, fdo#45366: Exception while importing xlsx."


It will be available in LibreOffice 3.6.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 21 Not Assigned 2012-09-24 08:55:02 UTC
Fridrich Å trba committed a patch related to this issue.
It has been pushed to "master":

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

Revert "fdo#54609: Exception while importing xlsx."



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 22 Fridrich Strba 2012-09-24 09:04:39 UTC
We found the root cause of the exception and fixed it. The fix will be present in 3.6.2 rc2 that is due later this week. Will be nice to verify then.