Printing PDF from Print Preview aborts debug build with "Assertion failure: !mAutoBeforeAndAfterPrint (We don't want to dispatch nested beforeprint/afterprint), at nsDocumentViewer.cpp:3563"
Categories
(Core :: Print Preview, defect, P3)
Tracking
()
People
(Reporter: bdahl, Unassigned)
References
Details
(Keywords: assertion)
Attachments
(1 file)
26.13 KB,
application/pdf
|
Details |
STR:
- Open PDF
- Open Print Preview
- Click Print
Assertion failure: !mAutoBeforeAndAfterPrint (We don't want to dispatch nested beforeprint/afterprint), at /home/bdahl/projects/gecko/layout/base/nsDocumentViewer.cpp:3563
JS BT:
0 print(contentWindow = [cross-compartment wrapper], simplifiedMode = false, defaultPrinterName = "CUPS/HP_Color_LaserJet_M452dw_C590A0_") ["resource://gre/actors/PrintingChild.jsm":343:6]
this = [object Object]
1 receiveMessage(message = [object Object]) ["resource://gre/actors/PrintingChild.jsm":98:8]
this = [object Object]
2 receiveMessage(message = [object Object]) ["resource://gre/modules/ActorManagerChild.jsm":160:29]
this = [object Object]
BT:
#0 0x00007fffea03aff5 in nsDocumentViewer::Print(nsIPrintSettings*, nsIWebProgressListener*) (this=0x7fffc6ae6ef0, aPrintSettings=0x7fffcb3c07e0, aWebProgressListener=0x0)
at /home/bdahl/projects/gecko/layout/base/nsDocumentViewer.cpp:3562
#1 0x00007fffe738379a in NS_InvokeByIndex ()
at /home/bdahl/projects/gecko/xpcom/reflect/xptcall/md/unix/xptcinvoke_asm_x86_64_unix.S:106
#2 0x00007fffe7ddbf4b in CallMethodHelper::Invoke() (this=<optimized out>)
at /home/bdahl/projects/gecko/js/xpconnect/src/XPCWrappedNative.cpp:1628
#3 0x00007fffe7ddbf4b in CallMethodHelper::Call() (this=0x7ffffffface0)
at /home/bdahl/projects/gecko/js/xpconnect/src/XPCWrappedNative.cpp:1186
#4 0x00007fffe7dcbcf9 in XPCWrappedNative::CallMethod(XPCCallContext&, XPCWrappedNative::CallMode) (ccx=..., mode=<optimized out>) at /home/bdahl/projects/gecko/js/xpconnect/src/XPCWrappedNative.cpp:1152
#5 0x00007fffe7dcce0a in XPC_WN_CallMethod(JSContext*, unsigned int, JS::Value*) (cx=<optimized out>, argc=<optimized out>, vp=<optimized out>)
at /home/bdahl/projects/gecko/js/xpconnect/src/XPCWrappedNativeJSOps.cpp:946
#6 0x00007fffeb3559e0 in CallJSNative(JSContext*, bool ()(JSContext, unsigned int, JS::Value*), JS::CallArgs const&) (cx=0x7fffde725000, native=0x7fffe7dccb81 <XPC_WN_CallMethod(JSContext*, unsigned int, JS::Value*)>, args=...) at /home/bdahl/projects/gecko/js/src/vm/Interpreter.cpp:442
#7 0x00007fffeb345533 in js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct) (cx=0x7fffde725000, args=..., construct=js::NO_CONSTRUCT)
at /home/bdahl/projects/gecko/js/src/vm/Interpreter.cpp:534
#8 0x00007fffeb33c69a in js::CallFromStack(JSContext*, JS::CallArgs const&) (cx=<optimized out>, args=...) at /home/bdahl/projects/gecko/js/src/vm/Interpreter.cpp:593
#9 0x00007fffeb33c69a in Interpret(JSContext*, js::RunState&) (cx=<optimized out>, state=...)
at /home/bdahl/projects/gecko/js/src/vm/Interpreter.cpp:3069
#10 0x00007fffeb333934 in js::RunScript(JSContext*, js::RunState&) (cx=0x7fffde725000, state=...)
at /home/bdahl/projects/gecko/js/src/vm/Interpreter.cpp:422
Updated•6 years ago
|
Comment 1•6 years ago
|
||
Looks like this assertion was added in bug 1313386 (it's the first chunk of that bug's patch).
Comment 2•6 years ago
|
||
Comment 3•6 years ago
|
||
I'm guessing we fail the assertion because we dispatch beforePrint/afterprint on entering/exiting print preview, and so print-from-inside print-preview causes a nested scenario where we do
- dispatch beforeprint for entering print-preview
- dispatch beforeprint for print [assertion failure]
- dispatch afterprint for competing print
- dispatch afterprint for leaving print-preview
...or something like this.
Updated•2 years ago
|
Description
•