Bug 89441 - CRASH 64-bit Windows build in Draw if attempting to import a JPEG2000 image (JP2) with extension mislabeled as JPEG
Summary: CRASH 64-bit Windows build in Draw if attempting to import a JPEG2000 image (...
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
4.5.0.0.alpha0+ Master
Hardware: x86-64 (AMD64) Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 61683
  Show dependency treegraph
 
Reported: 2015-02-17 17:03 UTC by Dennis Roczek
Modified: 2016-04-16 14:26 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dennis Roczek 2015-02-17 17:03:02 UTC
Importing the image at
https://wiki.documentfoundation.org/File:Walrus-tdf-eyes_recreation_default-colorspace.jp2.jpeg and LibreOffice Windows x64 is crashing on Windows 8.1 Professional.

Version: 4.5.0.0.alpha0+ (x64)
Build ID: Built by David Ostrovsky
Locale: de_DE
Comment 1 V Stuart Foote 2015-02-17 22:36:01 UTC
Can not confirm.

No crash with 64-bit, just the same behavior as 32-bit builds.

On Windows 7 sp1, 64-bit en-US with Imagemagick 6.8.9.0 Q16 installed

Version: 4.5.0.0.alpha0+
Build ID: 40b1e8266e47792d354cd457c652bfb0f0a21e69
TinderBox: Win-x86@62-TDF, Branch:MASTER, Time: 2015-02-11_00:13:43
Locale: en_US

--the image is being opened in Writer with just "###" showing
--and on insert, shows as "unknown image format"

Actually, not sure the .JP2 (JPEG 2000) format images are correctly handled by any Windows version of LibreOffice.

This Wiki suggests the JP2 format does the same in Linux.

https://wiki.documentfoundation.org/Media_Support/Linux/Image_Tests
Comment 2 Robinson Tryon (qubit) 2015-02-17 23:34:56 UTC
(In reply to Dennis Roczek from comment #0)
> Importing the image at
> https://wiki.documentfoundation.org/File:Walrus-tdf-eyes_recreation_default-
> colorspace.jp2.jpeg and LibreOffice Windows x64 is crashing on Windows 8.1
> Professional.
> 
> Version: 4.5.0.0.alpha0+ (x64)
> Build ID: Built by David Ostrovsky
> Locale: de_DE

Maybe it's just crashing the 64bit-LibreOffice build?

cc'ing David here.
Comment 3 Dennis Roczek 2015-02-17 23:38:57 UTC
sorry, yes only 64 bit is crashing. 32 bit is giving a generic message "no image filter found" or whatever
Comment 4 V Stuart Foote 2015-02-18 20:05:35 UTC
Hmm, 64-bit will crash if you do not rename (remove) the .jpeg file extension. 

But if you remove it so the file carries the correct.jp2 extension--the 64-bit build just says it is an "Unknown image format".

Suspect the crash comes because Draw attempts to open it as a JPEG and not a JPEG 200 image. Irfanview complains similarly--and then handles it as JP2.

This is commented on in the file's  summary.
NOTE: Due to wiki file extension restrictions, you'll want to strip the extra '.jpeg' off the end of the filename.
Comment 5 Robinson Tryon (qubit) 2015-02-18 20:18:30 UTC
(In reply to V Stuart Foote from comment #4)
> Suspect the crash comes because Draw attempts to open it as a JPEG and not a
> JPEG 200 image.

But we all agree that Draw should not be so brittle :-)

> This is commented on in the file's  summary.
> NOTE: Due to wiki file extension restrictions, you'll want to strip the
> extra '.jpeg' off the end of the filename.

That's just due to (annoying) limitations on our TDF Wiki. On the plus side, I'm happy that said limitations lead to us discovering this crasher!
Comment 6 V Stuart Foote 2015-02-19 02:24:12 UTC
No crash with attempts to open by filter into Draw--although no current filter handling of JP2 image formats. 

Crash only occurs when attempting to import/insert into Draw a JP2 image that is mislabeled by file extension as JPEG image.

On crash, no error, no log of crash--just a hard end to LO. Document recovery on relaunch of LO.  I'm unable to get windbg past first chance errors to catch a stack trace.
Comment 7 tommy27 2016-04-16 07:22:31 UTC
** Please read this message in its entirety before responding **

To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year.

There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present.

If you have time, please do the following:

Test to see if the bug is still present on a currently supported version of LibreOffice (5.0.5 or 5.1.2 https://www.libreoffice.org/download/

If the bug is present, please leave a comment that includes the version of LibreOffice and your operating system, and any changes you see in the bug behavior
 
If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a short comment that includes your version of LibreOffice and Operating System

Please DO NOT

- Update the version field
- Reply via email (please reply directly on the bug tracker)
- Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not appropriate in this case)


If you want to do more to help you can test to see if your issue is a REGRESSION. To do so: 

1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3)

http://downloadarchive.documentfoundation.org/libreoffice/old/

2. Test your bug 

3. Leave a comment with your results. 

4a. If the bug was present with 3.3 - set version to "inherited from OOo"; 
4b. If the bug was not present in 3.3 - add "regression" to keyword


Feel free to come ask questions or to say hello in our QA chat: http://webchat.freenode.net/?channels=libreoffice-qa

Thank you for your help!

-- The LibreOffice QA Team This NEW Message was generated on: 2016-04-16
Comment 8 V Stuart Foote 2016-04-16 14:26:12 UTC
On Windows 10 Pro 64-bit en-US with
Version: 5.1.2.2 (x64)
Build ID: d3bf12ecb743fc0d20e0be0c58ca359301eb705f
CPU Threads: 8; OS Version: Windows 6.19; UI Render: GL; 
Locale: en-US (en_US)

With mislabeled JP2 image, Draw now provides an "Image filter not found" error pop-up which can be dismissed. And if mporting/inserting the correctly labeled .JP2 image identifies  with a warning "Unknown image format". Or if opening, the it is routed and opened in Writer.

Not sure this is all that is needed regards JPEG-2000 format (and have opened bug 99347), but believe this crash issue on 64-bit builds can be resolved WFM.