https://bugs.documentfoundation.org/show_bug.cgi?id=146478

            Bug ID: 146478
           Summary: vcldemo and other vcl examples exit with: "Aborted
                    (core dumped)"
           Product: LibreOffice
           Version: 7.4.0.0 alpha0+ Master
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: framework
          Assignee: libreoffice-bugs@lists.freedesktop.org
          Reporter: hoss...@libreoffice.org

Description:
When I start vcldemo from the LibreOffice source folder:

./bin/run vcldemo

and then close the application by clicking on the x button on the window, I
get:

(/lo/core is the LO source folder)

vcldemo: /lo/core/framework/source/services/desktop.cxx:1045: virtual void
framework::Desktop::disposing(): Assertion `m_bIsShutdown && "Desktop disposed
before terminating it"' failed.
Aborted (core dumped)

This is the same for mtfdemo, and other vcl applications. This does not only
happen in Linux, but also in Windows.

The same happen for the vcl example that I am writing, when disposing context:

125124: Minimal vcl application
https://gerrit.libreoffice.org/c/core/+/125124

    css::uno::Reference<css::lang::XComponent>(xContext,
css::uno::UNO_QUERY_THROW)->dispose();
    comphelper::setProcessServiceFactory(nullptr);

Note: When I remove the dispose() invocation, the abort message goes away.

This is the stack trace for 'vcldemo' created with gdb:

#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
#1  0x00007ffff48d4859 in __GI_abort () at abort.c:79
#2  0x00007ffff48d4729 in __assert_fail_base (
    fmt=0x7ffff4a6a588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", 
    assertion=0x7fffdbc7cb50 "m_bIsShutdown && \"Desktop disposed before
terminating it\"", 
    file=0x7fffdbc7cb00 "/lo/core/framework/source/services/desktop.cxx",
line=1045, function=<optimized out>)
    at assert.c:92
#3  0x00007ffff48e5f36 in __GI___assert_fail (
    assertion=0x7fffdbc7cb50 "m_bIsShutdown && \"Desktop disposed before
terminating it\"", 
    file=0x7fffdbc7cb00 "/lo/core/framework/source/services/desktop.cxx",
line=1045, 
    function=0x7fffdbc7cad0 "virtual void framework::Desktop::disposing()")
    at assert.c:101
#4  0x00007fffdb94b395 in framework::Desktop::disposing (
    this=0x555557205630)
    at /lo/core/framework/source/services/desktop.cxx:1045
#5  0x00007ffff73593e1 in cppu::WeakComponentImplHelperBase::dispose
(this=0x555557205630) at /lo/core/cppuhelper/source/implbase.cxx:104
#6  0x00007fffdb957474 in
cppu::PartialWeakComponentImplHelper<com::sun::star::lang::XServiceInfo,
com::sun::star::frame::XDesktop2, com::sun::star::frame::XTasksSupplier,
com::sun::star::frame::XDispatchResultListener,
com::sun::star::task::XInteractionHandler,
com::sun::star::frame::XUntitledNumbers>::dispose (this=0x555557205630) at
/lo/core/include/cppuhelper/compbase.hxx:90
#7  0x00007ffff73b132e in cppuhelper::ServiceManager::disposing
(this=0x55555560e590) at /lo/core/cppuhelper/source/servicemanager.cxx:920
#8  0x00007ffff73593e1 in cppu::WeakComponentImplHelperBase::dispose
(this=0x55555560e590) at /lo/core/cppuhelper/source/implbase.cxx:104
#9  0x00007ffff7349a20 in
cppu::PartialWeakComponentImplHelper<com::sun::star::lang::XServiceInfo,
com::sun::star::lang::XMultiServiceFactory,
com::sun::star::lang::XMultiComponentFactory, com::sun::star::container::XSet,
com::sun::star::container::XContentEnumerationAccess,
com::sun::star::beans::XPropertySet, com::sun::star::beans::XPropertySetInfo,
com::sun::star::lang::XEventListener,
com::sun::star::lang::XInitialization>::dispose (this=0x55555560e590) at
/lo/core/include/cppuhelper/compbase.hxx:90
#10 0x00007ffff732a1c8 in cppu::try_dispose (xInstance=...) at
/lo/core/cppuhelper/source/component_context.cxx:64
#11 0x00007ffff732c595 in cppu::(anonymous
namespace)::ComponentContext::disposing (this=0x55555573cd60) at
/lo/core/cppuhelper/source/component_context.cxx:430
#12 0x00007ffff73593e1 in cppu::WeakComponentImplHelperBase::dispose
(this=0x55555573cd60) at /lo/core/cppuhelper/source/implbase.cxx:104
#13 0x00007ffff733ff32 in
cppu::PartialWeakComponentImplHelper<com::sun::star::uno::XComponentContext,
com::sun::star::container::XNameContainer>::dispose (this=0x55555573cd60) at
/lo/core/include/cppuhelper/compbase.hxx:90
#14 0x0000555555578c9b in (anonymous namespace)::DemoApp::DeInit
(this=0x5555555ba160 <vclmain::createApplication()::aApp>) at
/lo/core/vcl/workben/vcldemo.cxx:2245
#15 0x00007ffff5c3fd51 in DeInitVCL () at
/lo/core/vcl/source/app/svmain.cxx:525
#16 0x00007ffff5c3eb83 in ImplSVMain () at
/lo/core/vcl/source/app/svmain.cxx:224
#17 0x00007ffff5c3ebd3 in SVMain () at /lo/core/vcl/source/app/svmain.cxx:231
#18 0x0000555555594361 in sal_main () at
/lo/core/vcl/source/salmain/salmain.cxx:34
#19 0x0000555555594338 in main (argc=1, argv=0x7fffffffdb98) at
/lo/core/vcl/source/salmain/salmain.cxx:29


Steps to Reproduce:
1. Compile LibreOffice from the sources
2. Start 'vcldemo' from the source folder using './bin/run vcldemo'
3. Close the application by clicking on the x button on the window

Actual Results:
'vcldemo' exits with: "Aborted (core dumped)"

Expected Results:
The 'vcldemo' should exit cleanly.


Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 7.4.0.0.alpha0+ / LibreOffice Community
Build ID: aecd4a6f57301d088bf0fdd7cc40fbdea8eab649
CPU threads: 8; OS: Linux 5.11; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

Version: 7.4.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 2a881af4e93f8744bc6bea43f3a06fa531626c22
CPU threads: 32; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: en-US (en_DE); UI: en-US
Calc: threaded

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to