Bug 117824 - Crash in: ScInputHandler::EnterHandler(ScEnterMode)
Summary: Crash in: ScInputHandler::EnterHandler(ScEnterMode)
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
6.0.4.2 release
Hardware: All All
: highest critical
Assignee: Caolán McNamara
URL:
Whiteboard: target:6.2.0 target:6.1.0.1 target:6.0.6
Keywords: bibisected, bisected, regression
: 117820 117974 118209 118368 118863 (view as bug list)
Depends on:
Blocks:
 
Reported: 2018-05-26 16:21 UTC by Mike Kaganski
Modified: 2018-07-21 12:27 UTC (History)
7 users (show)

See Also:
Crash report or crash signature: ["ScInputHandler::EnterHandler(ScEnterMode)"]


Attachments
A FODT document and a datasource to reproduce (9.01 KB, application/x-zip-compressed)
2018-05-26 16:21 UTC, Mike Kaganski
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Kaganski 2018-05-26 16:21:12 UTC
Created attachment 142296 [details]
A FODT document and a datasource to reproduce

This bug was filed from the crash reporting server and is br-a1abcdbb-6ba9-404c-b078-03c9bc83bb4b.
=========================================

1. Open the .fodt from attachment
2. Start Mail Merge Wizard
3. Click "Next" twice.
4. On the third page (Insert address block), click "Select address list" -> "Add", and choose the .ODS datasource from attachment; close the Select Address List dialog using OK.
5. Click "Cancel" to close the wizard.

=> Crash.
Comment 1 MM 2018-05-26 18:56:13 UTC
Confirmed on windows 7 x64 with Version: 6.0.4.2 (x64)
Build ID: 9b0d9b32d5dcda91d2f1a96dc04c645c450872bf
CPU threads: 3; OS: Windows 6.1; UI render: default

First you'll get a small (empty) window which says 'fatal error' as title. When clicking 'ok', LO quits.
Comment 2 Xisco Faulí 2018-05-28 14:55:39 UTC
Regression introduced by:

author	Caolán McNamara <caolanm@redhat.com>	2018-04-07 20:24:40 +0100
committer	Caolán McNamara <caolanm@redhat.com>	2018-04-09 11:03:37 +0200
commit 91bb474cc5342b32dab6c701a1bea6c49b87f498 (patch)
tree 959797bef23b50b4f653d3579909ff20162a89ed
parent 06d8e6264487e3084b583e5158d9b89f8480b3eb (diff)
forcepoint#37 revert tdf#108572 let remove storage element
reverts

commit 26957fc325c27cf61e8ef5555b380d627def4931
Date:   Wed Sep 6 10:54:50 2017 +0200

    tdf#108572 let remove storage element

    void OStorage_Impl::RemoveElement( SotElement_Impl* pElement )
    expects that m_pAntiImpl will be nullptr, if not throws an exception.
    This caused that in case of deleting embedded database used for
    mail merge it wasn't fully removed and

The problem is that by allowing the removal of the element, existing readonly
accessors are left pointing to the deleted element which causes quite some problems
as seen in this sample document

Bisected with: bibisect-linux64-6.1

Adding Cc: to Caolán McNamara
Comment 3 Caolán McNamara 2018-05-29 20:36:24 UTC
something has that storage element open for editing already so trying to remove it throws that exception.
Comment 4 Miklos Vajna 2018-05-30 13:00:01 UTC
I wonder if logging the calls to OStorage::openStreamElement() and OStorage::openStorageElement() + their closing would find who leaks the opened stream here.
Comment 5 Xisco Faulí 2018-06-05 10:09:17 UTC
*** Bug 117974 has been marked as a duplicate of this bug. ***
Comment 6 Caolán McNamara 2018-06-06 15:28:00 UTC
its the database itself which has the storage held open, https://gerrit.libreoffice.org/#/c/55388/ seems to work for me
Comment 7 Commit Notification 2018-06-07 07:30:39 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

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

tdf#117824 switch embedded database storage away from doc on revoke

It will be available in 6.2.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 8 Caolán McNamara 2018-06-07 07:54:25 UTC
backports in gerrit
Comment 9 Commit Notification 2018-06-07 11:56:20 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-1":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=34a3231103adcbcc71e0cc5e8b8f8b0bc1edb520&h=libreoffice-6-1

tdf#117824 switch embedded database storage away from doc on revoke

It will be available in 6.1.0.1.

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 10 Commit Notification 2018-06-08 01:48:31 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=9ae93085c90bdd00bcbf796ab399154bb7ab9e39&h=libreoffice-6-0

tdf#117824 switch embedded database storage away from doc on revoke

It will be available in 6.0.6.

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 11 Xisco Faulí 2018-06-08 11:02:49 UTC
Verified in

Version: 6.2.0.0.alpha0+
Build ID: 2a7f74900fb646235b74d4c9bd4690e44edc3ed4
CPU threads: 4; OS: Linux 4.13; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: group threaded

@Caolán, Thanks for fixing this!
Comment 12 Xisco Faulí 2018-06-17 14:20:17 UTC
*** Bug 117820 has been marked as a duplicate of this bug. ***
Comment 13 Xisco Faulí 2018-06-17 14:21:32 UTC
*** Bug 118209 has been marked as a duplicate of this bug. ***
Comment 14 Xisco Faulí 2018-06-25 08:38:04 UTC
*** Bug 118368 has been marked as a duplicate of this bug. ***
Comment 15 Xisco Faulí 2018-07-21 12:27:42 UTC
*** Bug 118863 has been marked as a duplicate of this bug. ***