Bug 168599 - Draw Crashes on new document when pressing CTRL+pgUp/pgDown
Summary: Draw Crashes on new document when pressing CTRL+pgUp/pgDown
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
25.8.1.1 release
Hardware: All All
: medium normal
Assignee: Mike Kaganski
URL:
Whiteboard: target:26.2.0 target:25.8.3 target:25...
Keywords: bibisected
Depends on:
Blocks:
 
Reported: 2025-09-29 06:53 UTC by T eriksson
Modified: 2025-09-30 01:05 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description T eriksson 2025-09-29 06:53:39 UTC
Description:
Crash on new document or possibly any document containing only one page. Adding  page to the document fixes the bug partly.

Steps to Reproduce:
1. Open a new draw document
2. Press ctrl+pgUp or ctrl+pgDown
3.

Actual Results:
Immidiate crash

Expected Results:
No action really, since it's a single page document


Reproducible: Always


User Profile Reset: No

Additional Info:
libre office community version: 25.8.2.1
Comment 1 Jim Raykowski 2025-09-29 08:17:30 UTC
I repro the crash with:

Version: 26.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 0d986755e4153230670c820dc52cc40cd72dfa87
CPU threads: 2; OS: Linux 6.14; UI render: default; VCL: x11
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

Seems this patch is where it started:

commit 3cb0678a9cac9a681903b5a082d1c5dd5f25f665 
Author: Noel Grandin <noel.grandin@collabora.co.uk>
Date: Tue Mar 4 15:37:15 2025 +0200 (7 months ago)

fix dodgy DrawController::fireChangeLayer code
Comment 2 Mike Kaganski 2025-09-29 08:19:02 UTC
https://gerrit.libreoffice.org/c/core/+/191593
Comment 3 Commit Notification 2025-09-29 09:39:06 UTC
Mike Kaganski committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/16a0b42a4f79a20a2aaf8dd443c55b81a8084351

tdf#168599: don't create Any from a direct reference to an interface

It will be available in 26.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 4 Mike Kaganski 2025-09-29 09:44:05 UTC
(In reply to T eriksson from comment #0)
> Expected Results:
> No action really, since it's a single page document

In fact, there *is* an expected action, which is changing the current layer :-)
Comment 5 Commit Notification 2025-09-29 10:54:22 UTC
Mike Kaganski committed a patch related to this issue.
It has been pushed to "libreoffice-25-8":

https://git.libreoffice.org/core/commit/ecb65b032dc169cda9e5beed2d2a61ab47619bdb

tdf#168599: don't create Any from a direct reference to an interface

It will be available in 25.8.3.

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 6 Commit Notification 2025-09-29 14:25:45 UTC
Mike Kaganski committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/7c1c72095af014d1635b76dff58cc91fb807abcc

Related: tdf#168599 Disallow constructing Any from const XInterface&

It will be available in 26.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 7 Commit Notification 2025-09-29 14:55:25 UTC
Mike Kaganski committed a patch related to this issue.
It has been pushed to "libreoffice-25-8-2":

https://git.libreoffice.org/core/commit/c2c6290671c3c3696a07af28d8b50641fcedde2a

tdf#168599: don't create Any from a direct reference to an interface

It will be available in 25.8.2.

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 8 Jim Raykowski 2025-09-30 01:05:12 UTC
Thanks Mike for the fix and detailed explanation of the cause of the crash included in the patch comment.

Setting this ticket to Verified Fixed.

Tested with:
Version: 26.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 4f33bb0f672a450ee5f2a4fd502398f2008fd7a8
CPU threads: 2; OS: Linux 6.14; UI render: default; VCL: x11
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded