Bug 93487 - FORMATTING: Using Borders button on toolbar crashes Calc
Summary: FORMATTING: Using Borders button on toolbar crashes Calc
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
5.0.0.5 release
Hardware: x86-64 (AMD64) Linux (All)
: medium major
Assignee: Not Assigned
URL:
Whiteboard: target:5.1.0 target:5.0.4
Keywords: haveBacktrace
: 94078 94170 95678 96313 96350 (view as bug list)
Depends on:
Blocks: VclPtr
  Show dependency treegraph
 
Reported: 2015-08-17 17:02 UTC by Chu Chin Kuan
Modified: 2016-10-25 19:17 UTC (History)
13 users (show)

See Also:
Crash report or crash signature:


Attachments
--backtrace log (6.00 KB, text/x-log)
2015-08-20 15:59 UTC, Chu Chin Kuan
Details
backtrace from abrt (56.46 KB, text/plain)
2015-09-11 09:03 UTC, Nils Smeds
Details
Output of --strace (361.96 KB, application/x-lzma)
2015-10-09 12:05 UTC, Sean Russell
Details
--backtrace output (1.53 KB, application/x-lzma)
2015-10-09 12:06 UTC, Sean Russell
Details
Debug info backtrace 5.1 alpha Build aa2886cf...982a777f (9.90 KB, text/plain)
2015-10-15 19:05 UTC, Nils Smeds
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Chu Chin Kuan 2015-08-17 17:02:27 UTC
Using the "Borders" or "Border Style" buttons on the Formatting toolbar causes Calc to crash without any error messages. Applying borders using the "Format cells" option from the right-click menu still works, only the buttons on the toolbar seems to be broken.

Steps to reproduce:
1. Create a new spreadsheet.
2. Select any cell.
3. Click on the "Borders" or "Border Style" button.
4. Select any border option in the pop-out.
R. Calc crashes without any error messages.

I am using Arch Linux x86_64.
Comment 1 raal 2015-08-20 11:03:26 UTC
Hello,
I can't confirm with Version: 5.1.0.0.alpha1+
Build ID: 6b7354ae66db40246a09e00aa876443057655a43
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2015-08-19_01:05:16

 For the test, could you rename your LibreOffice directory profile (see https://wiki.documentfoundation.org/UserProfile) and give it a new try? Thank you
Comment 2 Chu Chin Kuan 2015-08-20 15:59:43 UTC
Created attachment 118046 [details]
--backtrace log

I did as you asked, but it still crashes whenever I use those toolbar buttons. Here is the backtrace log.
Comment 3 sophie 2015-08-25 12:46:08 UTC
Hi, I couldn't reproduce using Ubuntu 15.04 and Version: 5.0.0.5
Build ID: 437e4abdf9e72fd0a6e6f8697a0e659bc77f9b10
Locale: fr-FR (fr_FR.UTF-8) 
5.0.1 will be soon available, could you test again with it and keep us informed? Thanks!
Added keywords: have-backtrace. Left as unconfirmed - Sophie
Comment 4 Nils Smeds 2015-09-09 21:12:27 UTC
I see the issue too. 
Tried removing the user profile but no change.

Tried Linux x86_64 rpm versions 5.0.1.2-2 and 5.0.2.1-1

echo $LANG
en_US.utf8

cat /etc/fedora-release 
Fedora release 22 (Twenty Two)

uname -a
Linux nsmeds-t440 4.1.6-200.fc22.x86_64 #1 SMP Mon Aug 17 19:54:31 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

XFCE window manager
xfce4-settings-4.12.0-5.fc22.x86_64
Comment 5 Maxim Monastirsky 2015-09-09 23:29:53 UTC
*** Bug 94078 has been marked as a duplicate of this bug. ***
Comment 6 Maxim Monastirsky 2015-09-09 23:31:53 UTC
2 confirmation -> NEW.
Comment 7 Jean-Baptiste Faure 2015-09-10 05:04:49 UTC
No crash for me with Version: 5.0.3.0.0+
Build ID: 651205cdf64d3fce6685a58587c8ec4626278779
Ubuntu_15.04_x86-64
Locale : fr-FR (fr_FR.UTF-8)

It seems that the problem is related to the window manager XFCE or LXDE.
@reporter: what is your window manager?

Best regards. JBF
Comment 8 Chu Chin Kuan 2015-09-10 06:56:03 UTC
It still crashes on version 5.0.1.2.0+ on AwesomeWM 3.5.6-2 for me.

Build ID: 5.0.1.2 Arch Linux build-1
Locale: en-GB (en_GB.utf8)

I also tested this version on KDE (KWin 5.4.0) and Xfce (xfwm4 version 4.12.3 r.7fdcb53 for Xfce 4.12). Both of them don't crash and work just fine.

Before this, on version 5.0.0.5, it crashes on both AwesomeWM and Xfce. I didn't test KDE because I didn't have it installed at the time.
Comment 9 Nils Smeds 2015-09-10 08:34:26 UTC
Tried latest build - no change

Version: 5.0.3.0.0+
Build ID: 315a112f28b480e8e90d42a8ab45d1b448490939
TinderBox: Linux-rpm_deb-x86_64@46-TDF, Branch:libreoffice-5-0, Time: 2015-09-10_06:47:25
Locale: en-US (en_US.utf8)

So far only the buttons "Borders" and "Border Style" crashes the GUI.

As before: Fedora 22 and XFCE window manager

So interaction between the WM and LO is a candidate root cause.

I will try to later today try another system where I can change the WM and see what happens.
Comment 10 Nils Smeds 2015-09-11 08:36:32 UTC
Tried a different Fedora 22 system. With xfce I can reproduce the crash, with GNOME I can not.

This system actually filed a bug report :-)

https://retrace.fedoraproject.org/faf/reports/800921/

Version: 5.0.3.0.0+
Build ID: 315a112f28b480e8e90d42a8ab45d1b448490939
TinderBox: Linux-rpm_deb-x86_64@46-TDF, Branch:libreoffice-5-0, Time: 2015-09-10_06:47:25
Locale: en-US (en_US.utf8)
Comment 11 Nils Smeds 2015-09-11 09:03:37 UTC
Created attachment 118602 [details]
backtrace from abrt

Version: 5.0.3.0.0+
Build ID: 315a112f28b480e8e90d42a8ab45d1b448490939
TinderBox: Linux-rpm_deb-x86_64@46-TDF, Branch:libreoffice-5-0, Time: 2015-09-10_06:47:25
Locale: en-US (en_US.utf8)

xfce4-session-4.12.1-3.fc22.x86_64
Comment 12 Sean Russell 2015-10-09 12:05:02 UTC
Same bug observed here.

Libreoffice:
Version: 5.1.0.0.alpha1+
Build ID: 902255645328efde34ddf62227c8278e8dd61ff0
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2015-07-30_05:23:12
Locale: en-US (en_US.UTF-8)

WM:
i3 version 4.10.4 (2015-09-08, branch "4.10.4")

OS:
Linux sting 4.1.0-040100rc3-generic #201505102036 SMP Mon May 11 00:37:27 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
Comment 13 Sean Russell 2015-10-09 12:05:17 UTC
Created attachment 119454 [details]
Output of --strace

Comment 12
Comment 14 Sean Russell 2015-10-09 12:06:16 UTC
Created attachment 119455 [details]
--backtrace output

Comment 12
Comment 15 Sean Russell 2015-10-09 12:09:07 UTC
*** Bug 94170 has been marked as a duplicate of this bug. ***
Comment 16 Michael Meeks 2015-10-15 10:50:10 UTC
Can't reproduce under XFCE here vs. either master or my own 5.0 build. Odd & sorry to be a pain. Any chance of a stack-trace and console output from a dbgutil build ? =)

Thanks !
Comment 17 Nils Smeds 2015-10-15 11:11:34 UTC
Do you need more detailed info than what is in 
https://bug-attachments.documentfoundation.org/attachment.cgi?id=118602

If so I'll try to locate and install a dbg image and repeat my steps for you.
Comment 18 Nils Smeds 2015-10-15 11:54:31 UTC
Installed release candidate 5.0.3.1-1 (RPM date Oct 8)
Build ID: fd8cfc22f7f58033351fcb8a83b92acbadb0749e
Locale: en-US (en_US.utf8)

Attached to soffice.bin with gdb and got the following. If this is not sufficient I'll need a link on how to get the necessary debug-info included in the install.

[...]
Reading symbols from /opt/libreoffice5.0/program/../program/libneon.so...(no debugging symbols found)...done.
Reading symbols from /lib64/libnss_dns.so.2...(no debugging symbols found)...done.
0x00007f07a920e2fd in poll () from /lib64/libc.so.6
Missing separate debuginfos, use: dnf debuginfo-install libreoffice5.0-5.0.3.1-1.x86_64
(gdb) cont
Continuing.

Program received signal SIGSEGV, Segmentation fault.
0x00007f07abff1d64 in vcl::Window::ImplGrabFocus(unsigned short) () from /opt/libreoffice5.0/program/libmergedlo.so
(gdb) where
#0  0x00007f07abff1d64 in vcl::Window::ImplGrabFocus(unsigned short) () at /opt/libreoffice5.0/program/libmergedlo.so
#1  0x00007f07abff232b in vcl::Window::ImplGrabFocus(unsigned short) () at /opt/libreoffice5.0/program/libmergedlo.so
#2  0x00007f07ac0408b9 in vcl::Window::dispose() () at /opt/libreoffice5.0/program/libmergedlo.so
#3  0x00007f07ab4ff0a6 in ValueSet::dispose() () at /opt/libreoffice5.0/program/libmergedlo.so
#4  0x00007f07ab9ffdcd in SvxFrameWindow_Impl::dispose() () at /opt/libreoffice5.0/program/libmergedlo.so
#5  0x00007f07ab2f2eb8 in SfxPopupWindow::Close() () at /opt/libreoffice5.0/program/libmergedlo.so
#6  0x00007f07abfcf00a in FloatingWindow::ImplEndPopupModeHdl(void*) () at /opt/libreoffice5.0/program/libmergedlo.so
#7  0x00007f07ac047f2c in ImplWindowFrameProc(vcl::Window*, SalFrame*, unsigned short, void const*) ()
    at /opt/libreoffice5.0/program/libmergedlo.so
#8  0x00007f07ac2a0858 in SalGenericDisplay::DispatchInternalEvent() () at /opt/libreoffice5.0/program/libmergedlo.so
#9  0x00007f079142d0e9 in GtkData::userEventFn(void*) () at /opt/libreoffice5.0/program/libvclplug_gtklo.so
#10 0x00007f079142d161 in call_userEventFn () at /opt/libreoffice5.0/program/libvclplug_gtklo.so
#11 0x00007f07a549da8a in g_main_context_dispatch () at /lib64/libglib-2.0.so.0
#12 0x00007f07a549de20 in g_main_context_iterate.isra () at /lib64/libglib-2.0.so.0
#13 0x00007f07a549decc in g_main_context_iteration () at /lib64/libglib-2.0.so.0
#14 0x00007f079142c4d3 in GtkData::Yield(bool, bool) () at /opt/libreoffice5.0/program/libvclplug_gtklo.so
#15 0x00007f07ac2365f3 in Application::Yield() () at /opt/libreoffice5.0/program/libmergedlo.so
#16 0x00007f07ac236675 in Application::Execute() () at /opt/libreoffice5.0/program/libmergedlo.so
#17 0x00007f07ab348b03 in desktop::Desktop::Main() () at /opt/libreoffice5.0/program/libmergedlo.so
#18 0x00007f07ac23b8e9 in ImplSVMain() () at /opt/libreoffice5.0/program/libmergedlo.so
#19 0x00007f07ac23b932 in SVMain() () at /opt/libreoffice5.0/program/libmergedlo.so
#20 0x00007f07ab367972 in soffice_main () at /opt/libreoffice5.0/program/libmergedlo.so
#21 0x000000000040075b in main ()

(gdb) list
1	freeblver.c: No such file or directory.

(gdb) info threads
  Id   Target Id         Frame 
  7    Thread 0x7ff342922700 (LWP 9091) "UpdateCheckThre" 0x00007ff35c4f78e9 in pthread_cond_timedwait@@GLIBC_2.3.2 () from /lib64/libpthread.so.0
  6    Thread 0x7ff34c9a3700 (LWP 9049) "rtl_cache_wsupd" 0x00007ff35c4f78e9 in pthread_cond_timedwait@@GLIBC_2.3.2 () from /lib64/libpthread.so.0
  5    Thread 0x7ff342121700 (LWP 9053) "OfficeIPCThread" 0x00007ff35d47786d in accept () from /lib64/libc.so.6
  4    Thread 0x7ff340ceb700 (LWP 9054) "SelectionManage" 0x00007ff35d46b2fd in poll () from /lib64/libc.so.6
  3    Thread 0x7ff333fff700 (LWP 9062) "ICEConnectionWo" 0x00007ff35d46b2fd in poll () from /lib64/libc.so.6
* 1    Thread 0x7ff3621d7a00 (LWP 9048) "soffice.bin" 0x00007ff36024ed64 in vcl::Window::ImplGrabFocus(unsigned short) ()
   from /opt/libreoffice5.0/program/libmergedlo.so
Comment 19 Michael Meeks 2015-10-15 17:32:22 UTC
> Do you need more detailed info than what is in ...

Yes sorry - can't reproduce here under XFCE; and having full stack & file information is really vital. You need a dbgutil build you can run - which should have symbols (and be quite big to download) - the wiki should point you to that somewhere. If you get a trace from that - it should have filenames eg. vcl/source/app/svapp.cxx:1234 next to symbols, with the values of the parameters that are passed etc.

Thanks !
Comment 20 Maxim Monastirsky 2015-10-15 19:01:06 UTC
(In reply to Michael Meeks from comment #19)
> can't reproduce here under XFCE;
I found how to reproduce. Under System Settings open "Window Manager Tweaks", switch to the Focus tab, and uncheck "Honor standard ICCCM focus hint".
Comment 21 Nils Smeds 2015-10-15 19:05:13 UTC
Created attachment 119650 [details]
Debug info backtrace 5.1 alpha Build aa2886cf...982a777f
Comment 22 Nils Smeds 2015-10-15 19:07:47 UTC
Version: 5.1.0.0.alpha1+
Build ID: aa2886cf7d86175fead49a038b16a77a982a777f
TinderBox: Linux-rpm_deb-x86_64@70-TDF-dbg, Branch:master, Time: 2015-10-15_01:19:42
Locale: en-US (en_US.utf8)


Program received signal SIGSEGV, Segmentation fault.
0x00007f9ce28397c1 in vcl::Window::ImplGrabFocus (this=0x0, nFlags=GetFocusFlags::NONE)
    at /home/buildslave/source/libo-core/vcl/source/window/mouse.cxx:200
200	/home/buildslave/source/libo-core/vcl/source/window/mouse.cxx: No such file or directory.

(gdb) bt
#0  0x00007f9ce28397c1 in vcl::Window::ImplGrabFocus(GetFocusFlags) (this=0x0, nFlags=GetFocusFlags::NONE)
    at /home/buildslave/source/libo-core/vcl/source/window/mouse.cxx:200
#1  0x00007f9ce28e1a0b in vcl::Window::GrabFocus() (this=0x0) at /home/buildslave/source/libo-core/vcl/source/window/window.cxx:3173
#2  0x00007f9cb300b75a in SvxFrameWindow_Impl::GetFocus() (this=0x2c90030)
    at /home/buildslave/source/libo-core/svx/source/tbxctrls/tbcontrl.cxx:1645
...
See attachment for full backtrace
Comment 23 Nils Smeds 2015-10-16 13:29:35 UTC
(In reply to Maxim Monastirsky from comment #20)
> (In reply to Michael Meeks from comment #19)
> > can't reproduce here under XFCE;
> I found how to reproduce. Under System Settings open "Window Manager
> Tweaks", switch to the Focus tab, and uncheck "Honor standard ICCCM focus
> hint".

I can confirm this on at least one of my system (where I tested this).
Comment 24 Michael Meeks 2015-10-23 05:13:47 UTC
Still can't reproduce but fixed the crasher in the trace with debug symbols =) thanks for that Nils; awaiting gerrit CI builds at:

https://gerrit.libreoffice.org/19542  and
https://gerrit.libreoffice.org/19541
Comment 25 Commit Notification 2015-10-26 10:41:16 UTC
Michael Meeks committed a patch related to this issue.
It has been pushed to "master":

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

tdf#93487 - protect GetFocus method call post dispose.

It will be available in 5.1.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 26 Commit Notification 2015-10-27 14:57:29 UTC
Michael Meeks committed a patch related to this issue.
It has been pushed to "libreoffice-5-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=a3a61471b0171a07a2dc38a5bbf1b51681ddb91a&h=libreoffice-5-0

tdf#93487 - protect GetFocus method call post dispose.

It will be available in 5.0.4.

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 27 Nils Smeds 2015-10-29 07:57:37 UTC
I can confirm that the nightly build 

Version: 5.0.4.0.0+
Build ID: 40cfb7780291a9ba5ca9be54371a2aa30db7a8eb
TinderBox: Linux-rpm_deb-x86_64@46-TDF, Branch:libreoffice-5-0, Time: 2015-10-28_00:26:20
Locale: en-US (en_US.utf8)

does not have the problem reported.
Comment 28 Maxim Monastirsky 2015-11-08 14:23:58 UTC
*** Bug 95678 has been marked as a duplicate of this bug. ***
Comment 29 Maxim Monastirsky 2015-12-07 18:17:14 UTC
*** Bug 96313 has been marked as a duplicate of this bug. ***
Comment 30 Maxim Monastirsky 2015-12-09 11:32:42 UTC
*** Bug 96350 has been marked as a duplicate of this bug. ***
Comment 31 l_ 2016-05-08 07:49:10 UTC
This Bug still exist.

---------------------

LibreOffice 5.0.6.3 00m0(Build:3)

Linux XPS13-9350 4.4.9-1-lts #1 SMP Thu May 5 07:43:50 CEST 2016 x86_64 GNU/Linux

i3 version 4.12 (2016-03-06, branch "4.12") © 2009 Michael Stapelberg and contributors
Comment 32 Maxim Monastirsky 2016-05-08 08:56:57 UTC
(In reply to l_ from comment #31)
> This Bug still exist.
Not sure what you mean by "this bug". If that's about the border style button - then it was fixed only last week in Bug 99338.
Comment 33 Mark van Rossum 2016-05-08 09:19:50 UTC
Fixed for me in 
Version: 5.1.3.2

Build ID: 5.1.3.2-2.fc24

I don't know when the fix first appeared.
Comment 34 jakub.st 2016-05-08 19:14:35 UTC
No, it's not fixed.
I use Ubuntu 16.04.
LibreOffice 5.1.2.2 10m0(Build:2)
libreoffice-calc/xenial,now 1:5.1.2-0ubuntu1 amd64 [installed,automatic]
i3 version 4.11 (2015-09-30, branch "4.11") © 2009 Michael Stapelberg and contributors

all from official repo.

And I know, maybe it's ubuntu fault, but I really don't care. I make bug report in ubuntu and debian bug trackers and I'm not interested in making reports all the time.

It's so obvious bug in so popular software (and i3 is quite popular too), that I lose faith in FLOSS.

I think, that it was fixed in ubuntu 15.10 for some time, but it doesn't matter.

It hard to believe that there is only one or two person that use Libreoffice Calc with i3.
Comment 35 Maxim Monastirsky 2016-05-08 19:24:59 UTC
(In reply to jakub.st from comment #34)
> No, it's not fixed.
> I use Ubuntu 16.04.
> LibreOffice 5.1.2.2 10m0(Build:2)
And the same question again: What _exactly_ isn't fixed? Only the "Border Style" button or also the "Borders" button?
Comment 36 jakub.st 2016-05-09 06:49:08 UTC
(In reply to Maxim Monastirsky from comment #35)
> (In reply to jakub.st from comment #34)
> > No, it's not fixed.
> > I use Ubuntu 16.04.
> > LibreOffice 5.1.2.2 10m0(Build:2)
> And the same question again: What _exactly_ isn't fixed? Only the "Border
> Style" button or also the "Borders" button?

Only "Border Style" button doesn't work .
Comment 37 Maxim Monastirsky 2016-05-09 08:07:27 UTC
(In reply to jakub.st from comment #36)
> Only "Border Style" button doesn't work .
Thanks. So it should be fixed now too - see Bug 99338 (which I put in 'See also') (only on master right now - I will try to backport the fix to 5-1 later today).