Details
-
Bug
-
Resolution: Fixed
-
P1: Critical
-
None
-
6.2.10, 6.5.3, 6.6.1
-
Windows 10 22H2, MSVC 2019 x64
-
e09cf6e7a (dev), a1ffdacd2 (6.7), 62735b085 (6.6)
Description
Steps to reproduce
- Load the WebEngine Widgets PrintMe Example (https://doc.qt.io/qt-6/qtwebengine-webenginewidgets-printme-example.html )
- Modify main.cpp as follows:
//view.setUrl(QUrl(QStringLiteral("qrc:/index.html"))); QWebEngineProfile::defaultProfile()->settings()->setAttribute(QWebEngineSettings::PluginsEnabled, true); view.setUrl(QUrl("https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf"));
- Build and run the project in Release mode
- Press [Ctrl]+[Shift]+P to activate the print dialog
- Select the "Microsoft Print To PDF" printer and print it to disk
Expected outcomes (5.15.15)
- The output file looks like a copy of dummy.pdf (see attached output-5.15.pdf)
- No crash
Actual outcomes (6.x)
- The output file looks like the Chromium PDF viewing pane, but doesn't contain the actual PDF content (see attached output-6.6.pdf)
- Qt 6.6.1 produces an error message in Release mode ("Invalid parameter passed to C runtime function") and crashes in Debug mode with the following backtrace:
Received fatal exception EXCEPTION_BREAKPOINT Backtrace: QWebEnginePage::setUrlRequestInterceptor [0x00007FF938029CE8+276867377] invalid_parameter [0x00007FF970417EC6+406] invalid_parameter [0x00007FF970417D90+96] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93E868B88+386176977] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93E8684FD+386175302] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93E86855D+386175398] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93E868431+386175098] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93E86874A+386175891] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93E85A113+386116956] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F326B7+477180672] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F32A6B+477181620] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F38B1C+477206373] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F24C7B+477124804] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F2561C+477127269] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F269B0+477132281] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F3FAE6+477234991] QWebEnginePage::setUrlRequestInterceptor [0x00007FF92807E615+8778334] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F3067E+477172423] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F3232C+477179765] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F3942B+477208692] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F3CAB2+477222651] QWebEnginePage::setUrlRequestInterceptor [0x00007FF937C73F9F+272976872] QWebEnginePage::setUrlRequestInterceptor [0x00007FF943F2CEF5+477158206] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93988ACDA+302430499] QWebEnginePage::setUrlRequestInterceptor [0x00007FF939888993+302421468] QWebEnginePage::setUrlRequestInterceptor [0x00007FF9398CB198+302693857] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93988A0A8+302427377] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93A362F2F+313801592] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93A356F0B+313752404] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93A357625+313754222] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93A357A60+313755305] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93A368336+313823103] QWebEnginePage::setUrlRequestInterceptor [0x00007FF92807E615+8778334] QWebEnginePage::setUrlRequestInterceptor [0x00007FF937E2D637+274784896] QWebEnginePage::setUrlRequestInterceptor [0x00007FF937FD31F7+276512320] QWebEnginePage::setUrlRequestInterceptor [0x00007FF937FE6B35+276592510] QWebEnginePage::setUrlRequestInterceptor [0x00007FF937FE5A3F+276588168] QWebEnginePage::setUrlRequestInterceptor [0x00007FF937D74226+274026095] QWebEnginePage::setUrlRequestInterceptor [0x00007FF937FF1438+276635777] QWebEnginePage::setUrlRequestInterceptor [0x00007FF937F814AD+276177142] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93EBCB1FD+389725766] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93639538C+246898645] QWebEnginePage::setUrlRequestInterceptor [0x00007FF936393F90+246893529] QWebEnginePage::setUrlRequestInterceptor [0x00007FF93638D0D1+246865178] QWebEnginePage::setUrlRequestInterceptor [0x00007FF936387D3D+246843782] QWebEnginePage::setUrlRequestInterceptor [0x00007FF9280FF25E+9305767] TargetGetStockObject [0x00007FF7ED2C49A3+287028] TargetGetStockObject [0x00007FF7EDA46CE7+8160376] TargetGetStockObject [0x00007FF7EDA46AEE+8159871] TargetGetStockObject [0x00007FF7EDA3E492+8125475] TargetGetStockObject [0x00007FF7EDA3E33E+8125135] TargetGetStockObject [0x00007FF7EDA3E1FE+8124815] TargetGetStockObject [0x00007FF7EDA3E52E+8125631] BaseThreadInitThunk [0x00007FFA3AAB7344+20] RtlUserThreadStart [0x00007FFA3C5226B1+33]
- Qt 6.2.10/6.5.3 might also crash if we click the "print" icon embedded in the PDF viewer
Attachments
Issue Links
- split to
-
QTBUG-123755 [Reg 6.2.12 -> 6.5.5+] Crash when printing from Qt WebEngine
- Closed
For Gerrit Dashboard: QTBUG-119878 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
525071,5 | Fix printing from PDF plugin | dev | qt/qtwebengine | Status: MERGED | +2 | 0 |
526900,2 | Fix printing from PDF plugin | 6.7 | qt/qtwebengine | Status: MERGED | +2 | 0 |
527032,4 | Fix printing from PDF plugin | 6.6 | qt/qtwebengine | Status: MERGED | +2 | 0 |
551705,1 | FIXUP: Workaround debug iterator issues with MSVC | 112-based | qt/qtwebengine-chromium | Status: ABANDONED | 0 | 0 |
551706,1 | FIXUP: Workaround debug iterator issues with MSVC | 118-based | qt/qtwebengine-chromium | Status: ABANDONED | 0 | 0 |