Bug 154473 - virtual SdrModel::~SdrModel(): Assertion `maAllIncarnatedObjects.empty()' failed
Summary: virtual SdrModel::~SdrModel(): Assertion `maAllIncarnatedObjects.empty()' failed
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.6.0.0 alpha0+
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:7.6.0
Keywords: haveBacktrace
Depends on:
Blocks: Crash-Assert
  Show dependency treegraph
 
Reported: 2023-03-30 11:20 UTC by Buovjaga
Modified: 2023-04-17 12:57 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
GDB trace of assertion crash (12.16 KB, text/plain)
2023-03-30 11:20 UTC, Buovjaga
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Buovjaga 2023-03-30 11:20:38 UTC
Created attachment 186312 [details]
GDB trace of assertion crash

Run a debug build.

1. Open attachment 185855 [details]
2. Follow the copy & paste instructions (copy line object into chart in edit mode, exit edit mode)
3. Quit LibreOffice

svx/source/svdraw/svdmodel.cxx:227: virtual SdrModel::~SdrModel(): Assertion `maAllIncarnatedObjects.empty()' failed

Arch Linux 64-bit, X11
Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 2ca71b5c6e0374254e7c75c75e54fa6a8caebfde
CPU threads: 8; OS: Linux 6.2; UI render: default; VCL: kf5 (cairo+xcb)
Locale: fi-FI (fi_FI.UTF-8); UI: en-US
Calc: threaded
Built on 30 March 2023
Comment 1 Julien Nabet 2023-03-30 20:28:59 UTC
Noel: could it be related to the patches concerning use of concrete types in chart2?
Comment 2 Noel Grandin 2023-03-31 11:16:09 UTC
This is related to the ref-counting of SdrObjects patch, it means that there is a leak somewhere.
Comment 3 Julien Nabet 2023-03-31 20:00:35 UTC
Thank you Noel for the feedback.

On pc Debian x86-64 with master sources updated today, I could reproduce this.
Here are console logs:
warn:xmloff:31788:31788:xmloff/source/style/xmlstyle.cxx:412: Unknown element urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0 loext:theme
warn:xmloff:31788:31788:xmloff/source/draw/shapeimport.cxx:352: unknown attribute urn:oasis:names:tc:opendocument:xmlns:text:1.0 text:anchor-type value=paragraph
warn:xmloff:31788:31788:xmloff/source/chart/SchXMLChartContext.cxx:392: unknown attribute http://www.w3.org/1999/xlink xlink:type value=simple
warn:legacy.osl:31788:31788:sw/source/core/unocore/unochart.cxx:972: XLabeledDataSequence in data source contains 0 entries
warn:legacy.osl:31788:31788:sw/source/core/unocore/unochart.cxx:972: XLabeledDataSequence in data source contains 0 entries
warn:sal.osl:31788:31788:sal/osl/unx/module.cxx:103: dlopen(/home/julien/lo/libreoffice/instdir/program/libjava_gcc3.so, 257): /home/julien/lo/libreoffice/instdir/program/libjava_gcc3.so: cannot open shared object file: No such file or directory
warn:sal.osl:31788:31788:sal/osl/unx/module.cxx:103: dlopen(/home/julien/lo/libreoffice/instdir/program/libgcc3_java.so, 257): /home/julien/lo/libreoffice/instdir/program/libgcc3_java.so: cannot open shared object file: No such file or directory
warn:chart2:31788:31788:chart2/source/controller/main/ControllerCommandDispatch.cxx:715: commandAvailable: command not in availability map:.uno:StatusBarVisible
warn:chart2:31788:31788:chart2/source/controller/main/ControllerCommandDispatch.cxx:715: commandAvailable: command not in availability map:.uno:StatusBarVisible
warn:xmloff:31788:31788:xmloff/source/text/XMLTextListAutoStylePool.cxx:163: getStyleFamilies() from XModel failed for export!
warn:xmloff:31788:31788:xmloff/source/style/impastpl.cxx:369: Adding duplicate family graphic with mismatching mapper ! P25SvXMLExportPropertyMapper 28XMLShapeExportPropertyMapper
warn:xmloff:31788:31788:xmloff/source/style/impastpl.cxx:369: Adding duplicate family presentation with mismatching mapper ! P25SvXMLExportPropertyMapper 28XMLShapeExportPropertyMapper
warn:xmloff:31788:31788:xmloff/source/draw/shapeexport.cxx:626: XMLShapeExport::exportShape(): exception during hyperlink export com.sun.star.beans.UnknownPropertyException message: "OnClick at /home/julien/lo/libreoffice/svx/source/unodraw/unoshape.cxx:1636"
warn:legacy.osl:31788:31788:sfx2/source/doc/sfxbasemodel.cxx:2981: SfxBaseModel::IsInitialized: this should have been caught earlier!
warn:xmloff.core:31788:31788:xmloff/source/core/xmlimp.cxx:920: DBG_UNHANDLED_EXCEPTION in setTargetDocument exception: com.sun.star.lang.NotInitializedException message: "at /home/julien/lo/libreoffice/sfx2/source/doc/sfxbasemodel.cxx:2993"
warn:svl.items:31788:31788:svl/source/items/itempool.cxx:442: old secondary pool: EditEngineItemPool of pool: XOutdevItemPool must be empty.
warn:legacy.osl:31788:31788:chart2/source/tools/LifeTime.cxx:59: This component is already disposed 
warn:chart2.main:31788:31788:chart2/source/controller/main/ChartController.cxx:185: a well known owner has caught a CloseVetoException after calling close(true)
warn:legacy.osl:31788:31788:chart2/source/tools/LifeTime.cxx:59: This component is already disposed 
warn:chart2:31788:31788:chart2/source/tools/LifeTime.cxx:119: This component is already disposed 
warn:legacy.osl:31788:31788:toolkit/source/helper/unowrapper.cxx:280: UnoWrapper::WindowDestroyed: inconsistency in the window's peers!
warn:xmloff:31788:31788:xmloff/source/text/XMLTextListAutoStylePool.cxx:163: getStyleFamilies() from XModel failed for export!
warn:xmloff:31788:31788:xmloff/source/text/XMLTextListAutoStylePool.cxx:163: getStyleFamilies() from XModel failed for export!
warn:xmloff:31788:31788:xmloff/source/text/XMLTextListAutoStylePool.cxx:163: getStyleFamilies() from XModel failed for export!
warn:legacy.osl:31788:31788:xmloff/source/style/xmlexppr.cxx:879: element item not handled in xml export
warn:chart2.tools:31788:31788:chart2/source/tools/WrappedPropertySet.cxx:137: found no inner property set to map to
warn:chart2:31788:31788:chart2/source/tools/LifeTime.cxx:119: This component is already disposed 
warn:svx:31788:31788:svx/source/svdraw/svdmodel.cxx:223: SdrModel::~SdrModel: Not all incarnations of SdrObjects deleted, possible memory leak
warn:svx:31788:31788:svx/source/svdraw/svdmodel.cxx:225: leaked instance of 10SdrPathObj
soffice.bin: /home/julien/lo/libreoffice/svx/source/svdraw/svdmodel.cxx:227: virtual SdrModel::~SdrModel(): Assertion `maAllIncarnatedObjects.empty()' failed.
Comment 4 Telesto 2023-04-05 20:25:37 UTC
Setting to NEW based on comment 3
Comment 5 Commit Notification 2023-04-17 12:57:58 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/41741d0417a11ab3033e4dc6c899646d42871546

tdf#154473 remove assert

It will be available in 7.6.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.