Bug 112696 - Crash in: SwFEShell::IsGroupSelected()
Summary: Crash in: SwFEShell::IsGroupSelected()
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
4.1 all versions
Hardware: All All
: high major
Assignee: Caolán McNamara
URL:
Whiteboard: target:6.3.0 target:6.2.0.1
Keywords: bibisected, bisected, haveBacktrace, regression
Depends on:
Blocks:
 
Reported: 2017-09-27 16:40 UTC by Xisco Faulí
Modified: 2018-12-03 10:25 UTC (History)
6 users (show)

See Also:
Crash report or crash signature: ["SwFEShell::IsGroupSelected()"]


Attachments
gdb backtrace (19.41 KB, text/plain)
2017-09-27 17:17 UTC, Xisco Faulí
Details
gdb traces (11.46 KB, text/plain)
2017-12-14 17:58 UTC, Julien Nabet
Details
Still crasing in master (3.52 MB, video/mp4)
2018-11-20 09:18 UTC, Xisco Faulí
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Xisco Faulí 2017-09-27 16:40:05 UTC
Steps to reproduce:
1. Open writer
2. View - Toolbars - Form Control
3. Make sure the wizard button is enabled
4. Click on more controls button
5. Add a Group Form
6. Add a new field and click Next until the wizard finishes
7. DO NOT DESELECT THE FORM
8. Right click - Group - Group
9. CRASH

Reproduced in

Version: 6.0.0.0.alpha0+
Build ID: 465092047d5fa6ec6dd369372e712d76554570ff
CPU threads: 4; OS: Linux 4.10; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: group
Comment 1 Xisco Faulí 2017-09-27 16:58:07 UTC
Regression introduced by:

author	Luke Deller <luke@deller.id.au>	2013-04-27 21:06:11 (GMT)
committer	David Tardon <dtardon@redhat.com>	2013-04-28 11:52:12 (GMT)
commit	57082b1243e86694b72c5e4fad013bf207bfe81a (patch)
tree	2e461c166beecb5b569c966a2aeceb90995a4b85
parent	2094610175140023cf8f904f8506c189e36dec06 (diff)
fdo#60910: discard UNO shape object in SdrObject::SetPage
The creation of the UNO shape in SdrObject::getUnoShape is influenced
by pPage, so when the page changes we need to discard the cached UNO
shape so that a new one will be created with the new page.

This replaces my first shot at a fix for fdo#60910 which reinstated a
line to discard the custom shape engine (and consequently the UNO shape) in
SdrObjCustomShape::InvalidateRenderGeometry.  That worked but did more
discarding than was necessary.

Bisected with: bibisect-41max and reverted locally as well.

Adding Cc: to Luke Deller
Comment 2 Xisco Faulí 2017-09-27 17:17:31 UTC
Created attachment 136567 [details]
gdb backtrace
Comment 3 Xisco Faulí 2017-09-27 17:20:13 UTC
@Caolan, @Michael,
I'm wondering if any of you could take a look at this one?
Comment 4 Caolán McNamara 2017-09-28 14:02:16 UTC
caolanm->dtardon: any idea what all this stuff is about ?
Comment 5 Julien Nabet 2017-12-12 20:52:37 UTC
Xisco: I did 1., 2., 3. and 4. but where's the button "Group Form"?
Comment 6 Xisco Faulí 2017-12-12 20:56:40 UTC
(In reply to Julien Nabet from comment #5)
> Xisco: I did 1., 2., 3. and 4. but where's the button "Group Form"?

Sorry -> Group Box: https://help.libreoffice.org/Common/More_Controls#Group_Box
Comment 7 Julien Nabet 2017-12-14 17:58:30 UTC
Created attachment 138450 [details]
gdb traces

On pc Debian x6-64 with master sources udpated today + enable-dbgutil + gtk3, I could reproduce this.

I attached gdb traces which include:
- bt with symbols
- some logs
- the content of some vars
Comment 8 Commit Notification 2018-11-19 21:06:38 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/+/2cb9c55e4da18fbfb2f578c46d094e6ca0d56fa1%5E%21

Resolves: tdf#112696 survive missing SwDrawContact

It will be available in 6.3.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 9 Commit Notification 2018-11-19 21:08:16 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-2":

https://git.libreoffice.org/core/+/f918e71d4e615fcc4527051a6e7f6bb4768d1269%5E%21

Resolves: tdf#112696 survive missing SwDrawContact

It will be available in 6.2.0.1.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 10 Xisco Faulí 2018-11-20 09:17:54 UTC
Hi Caolán,
Thanks for fixing this. Unfortunately it's still crashing if I click on the form once grouped...

Version: 6.2.0.0.beta1+
Build ID: c13f4d0a2ff503cdebbc789e1711f90e7b5fe379
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US
Calc: threaded

See attached video...
Comment 11 Xisco Faulí 2018-11-20 09:18:36 UTC
Created attachment 146813 [details]
Still crasing in master
Comment 12 Caolán McNamara 2018-11-28 14:31:24 UTC
I think what happens here is that the wizard groups together the checkbox and groupframe but the writer view still has the two elements selected, not the replacement group object, hence the option to "group" in the first place which goes away when you click elsewhere and reselect the thing.
Comment 13 Caolán McNamara 2018-11-28 15:47:50 UTC
plan b
Comment 14 Commit Notification 2018-11-28 19:49:05 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-2":

https://git.libreoffice.org/core/+/b39c91cf5a2c21924f8ac780dadab75a6a2a0713%5E%21

tdf#112696 if we select every member of a group, select the group itself

It will be available in 6.2.0.1.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 15 Commit Notification 2018-11-28 19:50:26 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/+/e0ac72a1b714adc8f2ed8a721a8c0c1894d183e2%5E%21

tdf#112696 if we select every member of a group, select the group itself

It will be available in 6.3.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 16 Caolán McNamara 2018-11-28 20:01:01 UTC
ok, that seems to work better
Comment 17 Commit Notification 2018-11-28 21:14:16 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/+/30a07561c19da050c7ca0a7a67868a6f6229a449%5E%21

Revert "Resolves: tdf#112696 survive missing SwDrawContact"

It will be available in 6.3.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 18 Xisco Faulí 2018-11-29 14:34:08 UTC
Verified in

Version: 6.3.0.0.alpha0+
Build ID: 00df4a5ae395607eab1f83aacfc1fb05eb93ecc9
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US
Calc: threaded

Now it show the Ungroup options directly...

@Caolán, Thanks for fixing this.
Comment 19 Commit Notification 2018-12-03 10:25:33 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-2":

https://git.libreoffice.org/core/+/e45c30858dec1dd705b9144fab981a3c8819ba96%5E%21

Revert "Resolves: tdf#112696 survive missing SwDrawContact"

It will be available in 6.2.0.1.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.