Bug 145863 - Crash when click on autofilter dropdown, cancel and then click on the dropdown again
Summary: Crash when click on autofilter dropdown, cancel and then click on the dropdow...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.3.0.0 alpha0+
Hardware: All Linux (All)
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:7.3.0 target:7.4.0 target:7.3....
Keywords: bibisected, bisected, haveBacktrace, regression
Depends on:
Blocks:
 
Reported: 2021-11-24 10:14 UTC by Kevin Suo
Modified: 2021-11-29 13:32 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:
Regression By:


Attachments
gdbtrace.log (30.02 KB, text/x-log)
2021-11-25 06:44 UTC, Kevin Suo
Details
gdbtrace-nondbg.log (18.44 KB, text/x-log)
2021-11-26 08:54 UTC, Kevin Suo
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin Suo 2021-11-24 10:14:54 UTC
Steps to Reproduce:
1. Open attachmen 56652.
2. Click the autofilter dropdown in A1, click Cancel, then click the dropdown again.

--> Crash.

Bibisected to range: 6f435016092953478b5636fe9078866500fc7b90..62924b92d6737579cc4709b410d311251d4e5517

This is a wide range because my bibisect builds has skipped those commits until 62924b92d6737579cc4709b410d311251d4e5517 which fixed the --enable-dconf build issue.

Version: 7.3.0.0.alpha1+ / LibreOffice Community
Build ID: 06bcff6649be811cf7eacf971e84a0f4ac029b04
CPU threads: 8; OS: Linux 5.14; UI render: default; VCL: gtk3
Locale: zh-CN (zh_CN.UTF-8); UI: zh-CN
Calc: threaded
Comment 1 Kevin Suo 2021-11-24 10:17:48 UTC
I am trying to bisect, but I suspect that the two commits by Caolán related to autofilter popdown/submenu are suspicious.

Adding Caolán McNamara to cc: would you please take a look? Thanks.
Comment 2 Kevin Suo 2021-11-24 13:35:04 UTC
attachment 56652 [details]
Comment 3 Kevin Suo 2021-11-24 15:20:01 UTC
Weird that I can not reproduce several hours later now...
Set to NEEDINFO from me myself.
Comment 4 Caolán McNamara 2021-11-24 15:25:08 UTC
FWIW I can't reproduce in Fedora 35 (gtk3-3.24.30-4.fc35) under wayland or x11 either.
Comment 5 m.a.riosv 2021-11-24 18:30:26 UTC
No repro,
Version: 7.3.0.0.alpha1+ (x64) / LibreOffice Community
Build ID: 918b62bea6cf82ce952c8d225dcabd4d08a2abf7
CPU threads: 4; OS: Windows 10.0 Build 21390; UI render: Skia/Vulkan; VCL: win
Locale: es-ES (es_ES); UI: en-US Calc: CL
Comment 6 m.a.riosv 2021-11-24 18:31:06 UTC
¿Clean profile?
Comment 7 Kevin Suo 2021-11-25 06:44:29 UTC
Created attachment 176485 [details]
gdbtrace.log

Set back to UNCONFIRMED as I now can reproduce.

Steps to Reproduce:
1. Open attachment 56652 [details].
2. Double-click on the autofilter dropdown in cell A1, then followed by a single-click.

-> Crash.

Gdb backtrace attached.

Bisected to the following which is the same commit as in bug 145864:

commit bec2ecda617bfaa3897836e8a5eca3fb8f619625 (HEAD -> kevin-bisect2)
Author: Caolán McNamara <caolanm@redhat.com>
Date:   Fri Nov 19 11:38:58 2021 +0000

    tdf#139460 improve autofilter sub-menu interaction under gtk
    
    so the submenu pops down when the mouse moves back into its parent.
    
    This removes layer of InterimItemWindow and for gtk (under wayland) the
    autofilter and its submenu can use native GtkPopovers

However, cherry-picking da5b1e251ee58eca7a971a3c9312bb9d8bdf7bc4 continues to crash.
Comment 8 Kevin Suo 2021-11-25 06:47:05 UTC
(In reply to m.a.riosv from comment #6)
> Clean profile?

Yes, clean profile + 'make distclean'. As explained, also crashes with the TDF daily build, thus not my build issue.

Fedora 34 Wayland gtk3.
Comment 9 Kevin Suo 2021-11-25 06:53:57 UTC
(In reply to Kevin Suo from comment #7)

It is the following commit on master:

commit 2acdb3e617658ca19de26e8928e42b4955622feb
Author: Caolán McNamara <caolanm@redhat.com>
Date:   Fri Nov 19 11:38:58 2021 +0000

    tdf#139460 improve autofilter sub-menu interaction under gtk

The commit hash was a different because I bisected via cherry-pick, due to the build failing issue in 62924b92d.
Comment 10 Caolán McNamara 2021-11-25 12:59:53 UTC
I can reproduce with that.
Comment 11 Commit Notification 2021-11-25 15:15:29 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/3057538549fb30a0f5312653a97216ba93f126a2

Resolves: tdf#145863 crash if popup closed before becoming truly visible

It will be available in 7.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 12 Kevin Suo 2021-11-26 01:30:49 UTC
Still crashes, with the same steps as in comment 7, on master as of e95a808.
Comment 13 Kevin Suo 2021-11-26 08:54:00 UTC
Created attachment 176516 [details]
gdbtrace-nondbg.log

The new crash (after your commit) happens in a non-dbg build, but does not happen in a --enable-dbgutil build.

The autogen.input parameters used in the non-dbg build are:

--without-help
--without-helppack-integration
--with-lang=zh-CN
--disable-online-update
--disable-breakpad
--without-junit
--disable-odk
--without-doxygen
--with-external-tar=/home/suokunlong/lo/source/external_tarballs
--with-referenced-git=/home/suokunlong/lo/source/core
--without-java
--disable-avahi
--enable-werror
Comment 14 Caolán McNamara 2021-11-26 19:32:55 UTC
I can't reproduce with dbgutil so I'll make a non-dbg build and try again
Comment 15 Caolán McNamara 2021-11-27 16:43:08 UTC
can reproduce now
Comment 16 Commit Notification 2021-11-27 21:23:29 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/d0a99c25a2e3ff1bc355444a8877166b82d85366

Resolves: tdf#145863 crash on click after quick double click

It will be available in 7.4.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 17 Commit Notification 2021-11-28 20:34:35 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-7-3":

https://git.libreoffice.org/core/commit/c3449cf4f2048b31ca19fb5e147cb579758fb63c

Resolves: tdf#145863 crash on click after quick double click

It will be available in 7.3.0.0.beta2.

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 Kevin Suo 2021-11-29 13:32:37 UTC
Verified fixed on master.