Bug 42178 - CRASH when PRINTING from Page Preview
Summary: CRASH when PRINTING from Page Preview
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Master old -3.6
Hardware: Other All
: highest critical
Assignee: Ivan Timofeev (retired)
URL:
Whiteboard:
Keywords: regression
Depends on:
Blocks: mab3.5
  Show dependency treegraph
 
Reported: 2011-10-24 16:07 UTC by rk601
Modified: 2011-12-23 13:26 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Page Preview and Print document CRASHES LibO 3.5.0 on OSX (146.84 KB, application/zip)
2011-10-24 16:07 UTC, rk601
Details

Note You need to log in before you can comment on or make changes to this bug.
Description rk601 2011-10-24 16:07:07 UTC
Created attachment 52720 [details]
Page Preview and Print document CRASHES LibO 3.5.0 on OSX

Printing a Writer document from Page Preview and Print document CRASHES LibO 3.5.0

As an example, we tested the desired functionality in the Master:

LibO-dev 3.5.0 
Build ID: f8c2d29-e8c71c5-9c6ea62-4b83b90
On OSX 10.6.8

Located at:

http://dev-builds.libreoffice.org/daily/MacOSX_10.6.7_Intel_no-moz/master/2011-10-24_13.56.07/

with

master~2011-10-24_13.56.07_LibO-Dev_OOO350m1_MacOS_x86_install_en-US.dmg

Steps to reproduce:

1. Open a new WRITER Text Document
OR
2. Open an existing document like "OSX_Space_Crash.odt"
3. Select File -> Page Preview
4. Click on the Print document

Expected results: Document is printed.
Actual results: OSX CRASHES!

See attachment for sample documents and screenshots (OSX_Crash_Test.zip).

Below is a partial Crash Report:

Process:         soffice [362]
Path:            /Applications/LibO-dev.app/Contents/MacOS/soffice
Identifier:      org.libreoffice.script
Version:         3.5.0 (???)
Code Type:       X86 (Native)
Parent Process:  launchd [128]

Date/Time:       2011-10-24 15:54:25.111 -0700
OS Version:      Mac OS X 10.6.8 (10K549)
Report Version:  6

Interval Since Last Report:          145931 sec
Crashes Since Last Report:           13
Per-App Interval Since Last Report:  53747 sec
Per-App Crashes Since Last Report:   2

Exception Type:  EXC_BAD_ACCESS (SIGBUS)
Exception Codes: KERN_PROTECTION_FAILURE at 0x0000000000000110
Crashed Thread:  0  Dispatch queue: com.apple.main-thread

Thread 0 Crashed:  Dispatch queue: com.apple.main-thread
0   libswlo.dylib                 	0x3654e89c SwCrsrShell::GetCrsr(unsigned char) const + 28
1   libswlo.dylib                 	0x36d00119 lcl_GetPrintUIOptions(SwDocShell*, SfxViewShell const*) + 313
2   libswlo.dylib                 	0x36d0e432 SwXTextDocument::getRenderer(long, com::sun::star::uno::Any const&, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) + 2706
3   libsfxlo.dylib                	0x0069d487 SfxPrinterController::SfxPrinterController(boost::shared_ptr<Printer> const&, com::sun::star::uno::Any const&, com::sun::star::uno::Any const&, com::sun::star::uno::Any const&, com::sun::star::uno::Reference<com::sun::star::view::XRenderable> const&, unsigned char, unsigned char, SfxViewShell*, com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&) + 1271
4   libsfxlo.dylib                	0x0069e152 SfxViewShell::ExecPrint(com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> const&, unsigned char, unsigned char) + 770
5   libsfxlo.dylib                	0x006a062c SfxViewShell::ExecPrint_Impl(SfxRequest&) + 588
6   libsfxlo.dylib                	0x0049b11a SfxShell::ExecuteSlot(SfxRequest&, SfxInterface const*) + 90
7   libswlo.dylib                 	0x36c9d3b7 SwPagePreView::Execute(SfxRequest&) + 2423
8   libsfxlo.dylib                	0x0048db12 SfxDispatcher::Call_Impl(SfxShell&, SfxSlot const&, SfxRequest&, unsigned char) + 530
9   libsfxlo.dylib                	0x0048e104 SfxDispatcher::PostMsgHandler(SfxRequest*) + 308
10  libsfxlo.dylib                	0x00654109 SfxHintPoster::LinkStubDoEvent_Impl(void*, void*) + 25
11  libvcllo.dylib                	0x019d9e2f ImplWindowFrameProc(Window*, SalFrame*, unsigned short, void const*) + 5583
12  libvcllo.dylib                	0x019e4483 AquaSalInstance::Yield(bool, bool) + 323
13  libvcllo.dylib                	0x0170c570 Application::Yield(bool) + 96
14  libvcllo.dylib                	0x0170c671 Application::Execute() + 97
15  libsofficeapp.dylib           	0x0006c41d desktop::Desktop::Main() + 6317
16  libvcllo.dylib                	0x01713da8 ImplSVMain() + 376
17  libvcllo.dylib                	0x019e314b AquaSalInstance::handleAppDefinedEvent(NSEvent*) + 75
18  libvcllo.dylib                	0x01a28c9b -[VCL_NSApplication sendEvent:] + 315
19  com.apple.AppKit              	0x98b47253 -[NSApplication run] + 917
20  com.apple.AppKit              	0x98b3f289 NSApplicationMain + 574
21  libvcllo.dylib                	0x019e4b97 ImplSVMainHook(int*) + 343
22  libvcllo.dylib                	0x01713e51 SVMain() + 17
23  libsofficeapp.dylib           	0x00097e65 soffice_main + 245
24  org.libreoffice.script        	0x00001ebe main + 30
25  org.libreoffice.script        	0x00001822 _start + 216
26  org.libreoffice.script        	0x00001749 start + 41
Comment 1 Rainer Bielefeld Retired 2011-10-24 21:37:58 UTC
[Reproducible] with Server installation of Master "LibO-dev 3.5.0 – WIN7 Home Premium (64bit) English UI [(Build ID:  d3d1481-3f8994a-2ba0a9f)]" (110909)

[Reproducible] with parallel installation of MinGW Master "LibO-dev 3.5.0 – WIN7 Home Premium (64bit) English UI [(Build ID:  308b7a2-e916bf9-9c6ea62-e1a2fb3)] (daily/MinGW_cross-compilation 2011-10-18_22.56.49)"

Every document will crash, even an empty one.

Works fine with  with "LibreOffice 3.4.3  - WIN7 Home Premium (64bit) German UI [OOO340m1 (Build:302)]", so Regression.

@Cédric:
Please feel free to reassign (or reset Assignee to default) if it’s not your area or if provided information is not sufficient. Please set Status to ASSIGNED if you accept this Bug.
Comment 2 Rainer Bielefeld Retired 2011-10-24 21:45:42 UTC
Also a problem for PDF export
Comment 3 Ivan Timofeev (retired) 2011-10-25 05:43:19 UTC
The possible guilty commit: http://cgit.freedesktop.org/libreoffice/core/commit/?id=be6629ac7481dd68cb2f2b52927f1dcd975d6ac9
In the "lcl_GetPrintUIOptions" function (sw/source/ui/uno/unotxdoc.cxx) pDocShell->GetWrtShell() always returns 0 in page preview.
Comment 4 Ivan Timofeev (retired) 2011-11-18 04:53:18 UTC
Fixed with http://cgit.freedesktop.org/libreoffice/core/commit/?id=ce888a74614aa83e17a34e557f416acb262419a1 . Thank you for the detailed report!
Comment 5 Björn Michaelsen 2011-12-23 13:26:01 UTC
Since all new unconfirmed bugs start in state UNCONFIRMED now and old unconfirmed bugs were moved to NEEDINFO with a explanatory comment, all bugs promoted above those bug states to NEW and later are automatically confirmed making the CONFIRMED whiteboard status redundant. Thus it will be removed.