lok: fix sidebar controller disposed objects

Desktop / LibreOffice - Henry Castro [collabora.com] - 7 April 2021 16:36 UTC

The property listener still holds a reference count of the sidebar controller so it is disposed after removing the listener when the windows objects had already disposed.

kit-3428938-3428936 2021-01-25 15:39:15.502557 [ kitbroker_001 ] SIG Fatal signal received: SIGSEGV Backtrace 3428938: loolforkit(_ZN7SigUtil13dumpBacktraceEv+0x4e)[0x56273955b7ac] loolforkit(+0x1d9723)[0x56273955b723] /lib/x86_64-linux-gnu/libpthread.so.0(+0x14140)[0x7f689e8f3140] instdir/program/libsfxlo.so(+0x4785f6)[0x7f689b5a45f6] instdir/program/libsfxlo.so(_ZN4sfx27sidebar17SidebarController19UpdateDeckOpenStateEv+0x74)[0x7f689b7a553c] instdir/program/libsfxlo.so(_ZN4sfx27sidebar17SidebarController15RequestOpenDeckEv+0xa0)[0x7f689b7a5316] instdir/program/libsfxlo.so(_ZN4sfx27sidebar20SidebarDockingWindow8GetFocusEv+0x3c)[0x7f689b79aa6e] instdir/program/libvcllo.so(_ZN3vcl6Window14CompatGetFocusEv+0x7f)[0x7f68966da653] instdir/program/libvcllo.so(+0x63427c)[0x7f689661b27c] instdir/program/libvcllo.so(_ZN3vcl6Window9GrabFocusEv+0x1d)[0x7f68966d693d] instdir/program/libvcllo.so(_ZN3vcl6Window7disposeEv+0x1dd5)[0x7f68966c94e5] instdir/program/libsfxlo.so(+0x6993a3)[0x7f689b7c53a3] instdir/program/libvcllo.so(_ZN16VclReferenceBase11disposeOnceEv+0x40)[0x7f68968f7188] instdir/program/libsfxlo.so(+0x6802e1)[0x7f689b7ac2e1] instdir/program/libsfxlo.so(_ZN4sfx27sidebar17SidebarController9disposingEv+0x218)[0x7f689b79ff40] instdir/program/libuno_cppuhelpergcc3.so.3(_ZN4cppu27WeakComponentImplHelperBase7disposeEv+0xef)[0x7f689d2d846b] instdir/program/libsfxlo.so(+0x68036a)[0x7f689b7ac36a] instdir/programlibsfxlo.so(_ZN4sfx27sidebar17SidebarController9disposingERKN3com3sun4star4lang11EventObjectE+0x43)[0x7f689b7a05e5] instdir/program/libsfxlo.so(_ZN4sfx27sidebar5Theme9disposingEv+0x1ae)[0x7f689b804450] instdir/program/libuno_cppuhelpergcc3.so.3(_ZN4cppu27WeakComponentImplHelperBase7disposeEv+0xef)[0x7f689d2d846b] instdir/program/libsfxlo.so(+0x6f5eec)[0x7f689b821eec] instdir/program/libuno_cppuhelpergcc3.so.3(_ZN4cppu27WeakComponentImplHelperBase7releaseEv+0x94)[0x7f689d2d81f0] instdir/program/libsfxlo.so(+0x16c58e)[0x7f689b29858e] instdir/program/libsfxlo.so(+0x17c6e7)[0x7f689b2a86e7] instdir/program/libsfxlo.so(+0x17af6c)[0x7f689b2a6f6c] instdir/program/libsfxlo.so(+0x16c21c)[0x7f689b29821c] instdir/program/libsfxlo.so(+0x16b4d4)[0x7f689b2974d4] instdir/program/libsfxlo.so(_ZN14SfxApplicationD1Ev+0x248)[0x7f689b293cf8] instdir/program/libsfxlo.so(_ZN14SfxApplicationD0Ev+0x18)[0x7f689b293d38] instdir/program/libsfxlo.so(+0x1863e0)[0x7f689b2b23e0] instdir/program/libfwklo.so(_ZN9framework7Desktop8shutdownEv+0x206)[0x7f689c67b47c] instdir/program/libsofficeapp.so(+0x2f14b)[0x7f689ddb814b] instdir/program/libvcllo.so(_ZN11Application7ExecuteEv+0x191)[0x7f6896db9f45] instdir/program/libsofficeapp.so(+0x325c5)[0x7f689ddbb5c5] instdir/program/libvcllo.so(_Z10ImplSVMainv+0x1f4)[0x7f6896dd68a6]

Change-Id: I03eb5fa76b7712c8e12cefa2fbf07eb3e169eeb8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113068

4c4af3435789 lok: fix sidebar controller disposed objects
sfx2/source/sidebar/SidebarController.cxx | 32 ++++++++++++++++---------------
1 file changed, 17 insertions(+), 15 deletions(-)

Upstream: cgit.freedesktop.org


  • Share