Bug 120920 - Assertion failure when switching slide layouts with text entered
Summary: Assertion failure when switching slide layouts with text entered
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
6.2.0.0.alpha1+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:6.2.0
Keywords: haveBacktrace
Depends on:
Blocks: Crash-Assert
  Show dependency treegraph
 
Reported: 2018-10-25 20:38 UTC by Aron Budea
Modified: 2018-11-27 04:19 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Backtrace (24.93 KB, text/plain)
2018-10-25 20:38 UTC, Aron Budea
Details
bt with debug symbols (10.73 KB, text/plain)
2018-10-28 16:14 UTC, Julien Nabet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Aron Budea 2018-10-25 20:38:14 UTC
Created attachment 146015 [details]
Backtrace

Use a debug build for the reproduction steps.

- Start a new presentation.
- Enter a character in the content text box.
- Switch to a different slide layout, eg. to "Title, Content".

=> Crash with an assertion failure.

Assert is triggered here:
#3  0x00007ffff734e412 in __GI___assert_fail (assertion=0x7ffff21dad88 "!(bListeningAlready && eDuplicateHanding == DuplicateHandling::Unexpected) && \"duplicate listener, try building with DBG_UTIL to find the other insert site.\"", file=0x7ffff21dad50 "/build/sources/libreoffice/svl/source/notify/lstner.cxx", line=103, function=0x7ffff21db560 <SfxListener::StartListening(SfxBroadcaster&, DuplicateHandling)::__PRETTY_FUNCTION__> "void SfxListener::StartListening(SfxBroadcaster&, DuplicateHandling)") at assert.c:101
#4  0x00007ffff20f44d8 in SfxListener::StartListening(SfxBroadcaster&, DuplicateHandling) (this=0x55555b23edf0, rBroadcaster=..., eDuplicateHanding=DuplicateHandling::Unexpected) at /build/sources/libreoffice/svl/source/notify/lstner.cxx:103

Attaching backtrace.

Observed using LO 6.2.0.0.alpha1+ (313392119522c21a6ecd14403d6f92c948149df7) / Ubuntu 18.04.
Comment 1 Aron Budea 2018-10-25 20:57:05 UTC
This seemed like a regression, as it start occurring in repo lo-linux-dbgutil-daily-till60, and could be bibisected to the following range:
https://cgit.freedesktop.org/libreoffice/core/log/?qt=range&q=c0cb8cb25cc028e8f4f4bc06ae1a07882cd8dbfd..791f93e01a847f475cd3f1ad5bf947ee1a45314e

However, it seems it's the assert that was added at that point:
https://cgit.freedesktop.org/libreoffice/core/commit/?id=bc9a2ba677ce3fcd46c2bbef6e8faeacb14292c1
author		Noel Grandin <noel.grandin@collabora.co.uk>	2017-08-10 10:39:59 +0200
committer	Noel Grandin <noel.grandin@collabora.co.uk>	2017-08-16 10:41:56 +0200

assert on duplicate listener in SfxListener
Comment 2 Julien Nabet 2018-10-28 16:14:27 UTC
Created attachment 146100 [details]
bt with debug symbols

On pc Debian x86-64 with master sources updated yesterday, I could reproduce this.
Comment 3 Julien Nabet 2018-10-28 16:15:33 UTC
Noel: thought you might be interested in this one.
Comment 4 Commit Notification 2018-11-01 05:45:14 UTC
Noel Grandin committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/+/ef9bfdfe4f4ef75ca65547face0db09af7352314%5E%21

tdf#120920 Assertion failure when switching slide layouts with text entered

It will be available in 6.2.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 5 Aron Budea 2018-11-27 04:19:59 UTC
Verified with a local master debug build (26caf1bc59c81704f11225e3e431e412deb8c475), thanks for the fix, Noel!