-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
6.9.2
-
None
Hi,
We are facing a crash while a QtWebEngine window is created inside an executable that runs as startup app. It crashed both Windows 10 and 11.
This is a sample application to trigger the error
#include <QtWidgets> #include <QtWebEngineWidgets> #include <qtwebenginewidgetsglobal.h> int main(int argc, char * argv[]) { QApplication app(argc, argv); QMainWindow *browser = new QMainWindow(); QWebEngineView *view = new QWebEngineView(browser); view->load(QUrl("https://www.google.com")); browser->setCentralWidget(view); browser->resize(1024, 768); browser->show(); return app.exec(); }
And this is the exception collected by the command fired as soon Windows is available
"Procdump.exe" -ma -e -t -w sample.exe
[0x0] ntdll!RtlReportFatalFailure+0x9 0x2b1018e9f0 0x7ffc645cf393 [0x1] ntdll!RtlReportCriticalFailure+0x97 0x2b1018ea40 0x7ffc645d8112 [0x2] ntdll!RtlpHeapHandleError+0x12 0x2b1018eb30 0x7ffc645d83fa [0x3] ntdll!RtlpHpHeapHandleError+0x7a 0x2b1018eb60 0x7ffc645de081 [0x4] ntdll!RtlpLogHeapFailure+0x45 0x2b1018eb90 0x7ffc644f5bf0 [0x5] ntdll!RtlpFreeHeapInternal+0x4e0 0x2b1018ebc0 0x7ffc644f47b1 [0x6] ntdll!RtlFreeHeap+0x51 0x2b1018ec80 0x7ffc620ff05b [0x7] ucrtbase!_free_base+0x1b 0x2b1018ecc0 0x7ffbee1d9817 [0x8] Qt6WebEngineCore!std::_Deallocate+0x2b (Inline Function) (Inline Function) [0x9] Qt6WebEngineCore!std::allocator<char>::deallocate+0x35 (Inline Function) (Inline Function) [0xa] Qt6WebEngineCore!std::basic_string<char,std::char_traits<char>,std::allocator<char> >::_Deallocate_for_capacity+0x35 (Inline Function) (Inline Function) [0xb] Qt6WebEngineCore!std::basic_string<char,std::char_traits<char>,std::allocator<char> >::_Tidy_deallocate+0x3f (Inline Function) (Inline Function) [0xc] Qt6WebEngineCore!std::basic_string<char,std::char_traits<char>,std::allocator<char> >::{dtor}+0x3f (Inline Function) (Inline Function) [0xd] Qt6WebEngineCore!logging::LogMessage::Flush+0x5c7 0x2b1018ecf0 0x7ffbee1d83d8 [0xe] Qt6WebEngineCore!logging::LogMessage::~LogMessage+0x18 0x2b1018f260 0x7ffbee18cbb1 [0xf] Qt6WebEngineCore!logging::`anonymous-namespace'::NotReachedLogMessage::{dtor}+0xc8 (Inline Function) (Inline Function) [0x10] Qt6WebEngineCore!logging::`anonymous namespace'::NotReachedLogMessage::`scalar deleting destructor'+0xe1 0x2b1018f290 0x7ffbee18c709 [0x11] Qt6WebEngineCore!std::default_delete<logging::LogMessage>::operator()+0xa (Inline Function) (Inline Function) [0x12] Qt6WebEngineCore!std::unique_ptr<logging::LogMessage,std::default_delete<logging::LogMessage> >::reset+0x16 (Inline Function) (Inline Function) [0x13] Qt6WebEngineCore!logging::CheckError::~CheckError+0x29 0x2b1018f2f0 0x7ffbee1928f9 [0x14] Qt6WebEngineCore!logging::NotReachedError::TriggerNotReached+0xa9 0x2b1018f320 0x7ffbea44bff8 [0x15] Qt6WebEngineCore!embedder_support::?A0xd3282a92::GetPreRS5UniversalApiContractVersion+0x4f (Inline Function) (Inline Function) [0x16] Qt6WebEngineCore!`embedder_support::`anonymous namespace'::GetUniversalApiContractVersion'::`2'::<lambda_1>::operator()+0x88 0x2b1018f370 0x7ffbea44e9aa [0x17] Qt6WebEngineCore!embedder_support::?A0xd3282a92::GetUniversalApiContractVersion+0x1de (Inline Function) (Inline Function) [0x18] Qt6WebEngineCore!embedder_support::?A0xd3282a92::GetWindowsPlatformVersion+0x1de (Inline Function) (Inline Function) [0x19] Qt6WebEngineCore!embedder_support::GetUserAgentMetadata+0xaea 0x2b1018f460 0x7ffbea44ea24 [0x1a] Qt6WebEngineCore!embedder_support::GetUserAgentMetadata+0x14 0x2b1018f8c0 0x7ffbea3a5da8 [0x1b] Qt6WebEngineCore!QtWebEngineCore::ProfileQt::ProfileQt+0x78 0x2b1018f8f0 0x7ffbea39e2fe [0x1c] Qt6WebEngineCore!QtWebEngineCore::ProfileAdapter::ProfileAdapter+0x27e 0x2b1018f920 0x7ffbea3e30d7 [0x1d] Qt6WebEngineCore!QtWebEngineCore::WebEngineContext::createDefaultProfileAdapter+0x87 0x2b1018fa70 0x7ffbea32877e [0x1e] Qt6WebEngineCore!QWebEngineProfile::defaultProfile+0x7e 0x2b1018fb10 0x7ffbea31a2ab [0x1f] Qt6WebEngineCore!QWebEnginePagePrivate::QWebEnginePagePrivate+0xab 0x2b1018fb40 0x7ffbea31a17d [0x20] Qt6WebEngineCore!QWebEnginePage::QWebEnginePage+0x2d 0x2b1018fc20 0x7ffc52ca853e [0x21] Qt6WebEngineWidgets!QWebEngineView::page+0x2f (Inline Function) (Inline Function) [0x22] Qt6WebEngineWidgets!QWebEngineView::load+0x3e 0x2b1018fc50 0x7ff612b81175 [0x23] sample+0x1175 0x2b1018fc80 0x7ff612b823b0 [0x24] sample+0x23b0 0x2b1018fce0 0x7ff612b81606 [0x25] sample+0x1606 0x2b1018fd70 0x7ffc636b7374 [0x26] kernel32!BaseThreadInitThunk+0x14 0x2b1018fdb0 0x7ffc6451cc91 [0x27] ntdll!RtlUserThreadStart+0x21 0x2b1018fde0 0x0
Is related with #QDS-15693 but the bug was closed because QDS stopped using QtWebEngine
Steps to obtain a dump for boot apps:
- Create example project called sample, compile and windeployqt
- Download procdump from Microsoft
- Create a sampledump.bat file in Desktop for quick access with "Procdump.exe" -ma -e -t -w sample.exe
- In Registry create inside "Computer\HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Run" a new key with the absolute path to the example project exe
- Log out of windows (or restart)
- Log in and double click sampledump.bat file as soon UI is available
- Procdump will log the crash and will create a dmp file
We tried to start procdump using registry but was not working properly so double click in Desktop worked
Thank you in advance