Bug 166107 - CRASH: Opening print dialog after print preview
Summary: CRASH: Opening print dialog after print preview
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
25.8.0.0 alpha0+
Hardware: All All
: highest critical
Assignee: Xisco Faulí
URL:
Whiteboard: target:25.8.0 target:24.8.7
Keywords: bibisected, bisected, haveBacktrace, regression
Depends on:
Blocks:
 
Reported: 2025-04-09 16:31 UTC by Xisco Faulí
Modified: 2025-04-16 15:29 UTC (History)
6 users (show)

See Also:
Crash report or crash signature: ["SwRenderData::ViewOptionAdjustStop()"]


Attachments
bt (5.97 KB, text/plain)
2025-04-09 18:11 UTC, Julien Nabet
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Xisco Faulí 2025-04-09 16:31:49 UTC
Steps to reproduce:
1. Open writer
2. File - Print -> Print to file
3. File - Print Preview
4. Close print preview
5. File - Print preview

-> Crash

Reproduced in

Version: 25.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 403b1dd4808f72a2cd5cd6397f1610d41882eb01
CPU threads: 8; OS: Linux 6.1; UI render: default; VCL: gtk3
Locale: es-ES (es_ES.UTF-8); UI: en-US
Calc: threaded
Comment 1 Xisco Faulí 2025-04-09 16:32:40 UTC
Regression introduced by:

commit 364f0bb1cac0e12f5f926857f61c2f329a353ec7	[log]
author	Tibor Nagy <tibor.nagy.extern@allotropia.de>	Wed Feb 28 11:13:10 2024 +0100
committer	Nagy Tibor <tibor.nagy.extern@allotropia.de>	Thu Feb 29 01:36:08 2024 +0100
tree 27ae9514609b90ec0c8e8170377200c8bb543751
parent 6a064b1967e06e40be40817deff99d00c1a8554f [diff]

tdf#155218 sc: fix regression page orientation in print dialog

Bisected with: bibisect-linux64-24.8
Comment 2 Xisco Faulí 2025-04-09 16:39:59 UTC
Increasing importance to highest/critical since this is one of the most reported crashes in 24.8 and 25.2 releases
Comment 3 Julien Nabet 2025-04-09 18:11:47 UTC
Created attachment 200260 [details]
bt

On pc Debian x86-64 with master sources updated today, I could reproduce this.
Comment 4 Xisco Faulí 2025-04-09 20:46:49 UTC
My take on it: https://gerrit.libreoffice.org/c/core/+/183948
Comment 5 Vladislav Tarakanov 2025-04-11 15:45:40 UTC
As far as I remember, this patch solves a bug described here: https://bugs.documentfoundation.org/show_bug.cgi?id=155218#c20. At least without this line, after closing the save to file dialog and scrolling in the document, the displayed print area in Calc will not match the page styles.

The line is needed to solve a cosmetic problem, so it can probably be removed in favor of fixing the critical problem, but in the long run it would be good to solve this problem too
Comment 6 Xisco Faulí 2025-04-14 11:09:19 UTC
(In reply to Vladislav Tarakanov from comment #5)
> As far as I remember, this patch solves a bug described here:
> https://bugs.documentfoundation.org/show_bug.cgi?id=155218#c20. At least
> without this line, after closing the save to file dialog and scrolling in
> the document, the displayed print area in Calc will not match the page
> styles.
> 
> The line is needed to solve a cosmetic problem, so it can probably be
> removed in favor of fixing the critical problem, but in the long run it
> would be good to solve this problem too

Hi Valdislav,
Indeed, the issue is back if the line is removed. Thanks for testing it.
Since it's a regression from a67cd7b3cf03163f87811f7080cabc49750c4fd5, maybe there is another way to fix both issues
Comment 7 Commit Notification 2025-04-15 10:41:44 UTC
Xisco Fauli committed a patch related to this issue.
It has been pushed to "master":

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

tdf#166107: remove unnecessary resetPrintArea()

It will be available in 25.8.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 8 Commit Notification 2025-04-16 15:29:07 UTC
Xisco Fauli committed a patch related to this issue.
It has been pushed to "libreoffice-24-8":

https://git.libreoffice.org/core/commit/631e5b4b427199f5bb978c21f4fa11616f10ac4e

tdf#166107: remove unnecessary resetPrintArea()

It will be available in 24.8.7.

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.