Bug 87303 - Embedded spreadsheet appears as "Object #" and picture of a plug when unselected
Summary: Embedded spreadsheet appears as "Object #" and picture of a plug when unselected
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: framework (show other bugs)
Version:
(earliest affected)
4.3.1.2 release
Hardware: All All
: medium major
Assignee: Michael Stahl (allotropia)
URL:
Whiteboard: target:4.5.0 target:4.4.2
Keywords: bibisected, bisected, regression
Depends on:
Blocks:
 
Reported: 2014-12-14 11:32 UTC by sebriese
Modified: 2015-12-17 08:41 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
.odt file with misbehaving spreadsheet on page 1 (220.86 KB, application/vnd.oasis.opendocument.text)
2014-12-14 11:32 UTC, sebriese
Details
Image of broken sheet (47.91 KB, image/jpeg)
2014-12-30 14:55 UTC, Buovjaga
Details

Note You need to log in before you can comment on or make changes to this bug.
Description sebriese 2014-12-14 11:32:31 UTC
Created attachment 110832 [details]
.odt file with misbehaving spreadsheet on page 1

I can usually access and update this imbedded spreadsheet, but when I go to do it a second time it does no display or print as  a spreadsheet, just a static picture of a electrical plug along with and "Object 1" label at the bottom. Strange... If I leave it alone until tomorrow (assuming tomorrow is not a weekend) it can be edited and deselected normally. I am running Windows XP as a VM. It does not seem to be a memory problem.
Comment 1 Buovjaga 2014-12-16 13:10:01 UTC
Edited text inside the embedded spreadsheet, clicked elsewhere, edited again saved & reopened, but no problems. Not sure, if the astrological alignment was correct at the time, though. I also did not sacrifice any goats while editing.

Win 7 64-bit 4.3.4.1 and Version: 4.5.0.0.alpha0+
Build ID: 170616e9f2d30c1302bbb5a7a4b588bc05cd5cc9
TinderBox: Win-x86@39, Branch:master, Time: 2014-12-12_01:58:46
Comment 2 Joel Madero 2014-12-16 15:30:33 UTC
Can you provide explicit steps of what you're doing? I'm setting this to NEEDINFO. Enumerated steps are always the best:

1. Open the attached file;
2. ...
3. ...

Observed:
Expected:

For instance, what does it mean when you say "when I go to do it a second time" Also can you provide a pdf of what you're seeing with the electrical plug static picture?

Once you do the above please set to UNCONFIRMED. Thanks!
Comment 3 sebriese 2014-12-17 16:20:14 UTC
This is interesting. I found the variable action causing the bug. The document contains sections in addition to the imbedded spreadsheet, so when it loads, I get this message:

"This document contains one or more links to external data.
"Would you like to change the document, and update all links
to get the most recent data?"
"Yes   No"

1. Answering No to this question and then 
2. clicking into the spreadsheet
3. and back out 
results in turning the spreadsheet to a bitmap that looks like a 2-prong Europe contiental electrical wall plug bitmap.

Interesting since the 'Yes / No' question has no impact on updating the spreadsheet. ( wish it did.) It only affects the sections content.
Comment 4 Buovjaga 2014-12-30 14:55:40 UTC
Created attachment 111517 [details]
Image of broken sheet

It's true that after answering "no" one can break the sheet like you describe. So is it really a bug?
Comment 5 sebriese 2014-12-30 15:22:45 UTC
The Writer message:
"This document contains one or more links to external data.
"Would you like to change the document, and update all links
to get the most recent data?"
"Yes   No"

applies to updating Sections, NOT the spreadsheet. The answer, therefore, should not affect the imbedded spreadsheet (let alone break it). This takes it out of the feature list and into the bug domain.

It is not uncommon to modify the spreadsheet without wanting the sections updated. In my case it essential. This makes it a serious bug.
Comment 6 Buovjaga 2014-12-30 15:31:08 UTC
Ok, NEW it is.

I tested on Win 7 64-bit Version: 4.5.0.0.alpha0+
Build ID: 57626f2132f73e4e42b31e364b25c5867336e718
TinderBox: Win-x86@42, Branch:master, Time: 2014-12-26_09:26:33
Comment 7 Buovjaga 2015-01-12 17:39:29 UTC
Linux test results with repro steps from comment 5:
No problem with 3.5, so bibisecting can be done!
4.5 alpha gave the plug immediately on opening when answering "No" to link update.

Ubuntu 14.10 64-bit Version: 4.5.0.0.alpha0+
Build ID: 9763b55eb946cf425220d26dab91bf220890b180
TinderBox: Linux-rpm_deb-x86_64@46-TDF-dbg, Branch:master, Time: 2015-01-08_12:56:53

LibreOffice 3.5.0rc3 
Build ID: 7e68ba2-a744ebf-1f241b7-c506db1-7d53735
Comment 8 Michael Stahl (allotropia) 2015-02-06 16:54:06 UTC
worked in 4.3.0.4, borked in 4.3.1.2

bibisect range: 5ab1098d5fbc1ba092da73af2b92e5bcdd7a3f8d 4625227ed8db6b738f47f193df48d2791fb25246

regression from:
commit d005acae3aa315921f2c331612131626c470bd22
Author:     Armin Le Grand <alg@apache.org>
AuthorDate: Thu Aug 7 09:59:26 2014 +0000
Commit:     Caolán McNamara <caolanm@redhat.com>
CommitDate: Sat Aug 9 14:13:08 2014 +0100

    Resolves: #i125386# secured user request and changed some bools to bitfield
Comment 9 Michael Stahl (allotropia) 2015-02-06 17:05:43 UTC
the embedded object in the attached document:

      <draw:frame draw:style-name="fr20" draw:name="PositionSummary" text:anchor-type="page" text:anchor-page-number="1" svg:x="0.1701in" svg:y="2.0098in" svg:width="7.8228in" svg:height="6.8547in" draw:z-index="118">
        <draw:object xlink:href="./Object 1" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
        <draw:image xlink:href="./ObjectReplacements/Object 1" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
      </draw:frame>


the replacement image refers to the file "./ObjectReplacements/Object 1" but this does not exist in the ODF package.

presumably this means that older LO versions would automatically regenerate the preview image in this case, while with the security fix from comment #8 that now depends on the answer to the "update links to external data" prompt.

referring to a non-existent image file means the document is broken anyway,
so it's not a serious problem.
Comment 10 Michael Stahl (allotropia) 2015-02-11 14:19:19 UTC
we can disable the update just for "linked" objects, not "embedded" ones

fixed on master
Comment 11 Commit Notification 2015-02-11 14:19:35 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

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

tdf#87303: svtools: relax the security a bit for embedded objects

It will be available in 4.5.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 12 Commit Notification 2015-02-11 21:02:17 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-4-4":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=cbcfc31b124921d225323370f51f8eb8552d329a&h=libreoffice-4-4

tdf#87303: svtools: relax the security a bit for embedded objects

It will be available in 4.4.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 13 Robinson Tryon (qubit) 2015-12-17 08:41:33 UTC
Migrating Whiteboard tags to Keywords: (bibisected)
[NinjaEdit]