Tab teardown crashing resulting from renewed renderer destruction order issues #1591

Closed
opened 2026-01-30 22:31:22 +00:00 by claunia · 1 comment
Owner

Originally created by @DHowett-MSFT on GitHub (Jun 11, 2019).

Originally assigned to: @DHowett-MSFT on GitHub.

I can reliably crash a release build of WT by just closing tabs.

>	TerminalControl.dll!Microsoft::Console::Render::DxEngine::_CreateDeviceResources(const bool) Line 170	C++
 	TerminalControl.dll!Microsoft::Console::Render::DxEngine::StartPaint() Line 692	C++
 	TerminalControl.dll!Microsoft::Console::Render::Renderer::_PaintFrameForEngine(Microsoft::Console::Render::IRenderEngine * const pEngine) Line 90	C++
 	TerminalControl.dll!Microsoft::Console::Render::Renderer::PaintFrame() Line 68	C++
 	[Inline Frame] TerminalControl.dll!Microsoft::Console::Render::RenderThread::_ThreadProc()	C++
 	TerminalControl.dll!Microsoft::Console::Render::RenderThread::s_ThreadProc(void * lpParameter) Line 151	C++

Various things under RenderThread::s_ThreadProc.

If you ask the Renderer what it thinks, it says this:

this->_destructing
true

However, we're here:

b9d83baaeb/src/renderer/base/renderer.cpp (L59-L71)

We passed the _destructing check and . . . now we're very sad.

Originally created by @DHowett-MSFT on GitHub (Jun 11, 2019). Originally assigned to: @DHowett-MSFT on GitHub. I can reliably crash a release build of WT by just closing tabs. ``` > TerminalControl.dll!Microsoft::Console::Render::DxEngine::_CreateDeviceResources(const bool) Line 170 C++ TerminalControl.dll!Microsoft::Console::Render::DxEngine::StartPaint() Line 692 C++ TerminalControl.dll!Microsoft::Console::Render::Renderer::_PaintFrameForEngine(Microsoft::Console::Render::IRenderEngine * const pEngine) Line 90 C++ TerminalControl.dll!Microsoft::Console::Render::Renderer::PaintFrame() Line 68 C++ [Inline Frame] TerminalControl.dll!Microsoft::Console::Render::RenderThread::_ThreadProc() C++ TerminalControl.dll!Microsoft::Console::Render::RenderThread::s_ThreadProc(void * lpParameter) Line 151 C++ ``` Various things under `RenderThread::s_ThreadProc`. If you ask the `Renderer` what it thinks, it says this: ``` this->_destructing true ``` However, we're here: https://github.com/microsoft/terminal/blob/b9d83baaeb149410dc8e520ec829eb891b2087a7/src/renderer/base/renderer.cpp#L59-L71 We passed the `_destructing` check and . . . now we're very sad.
Author
Owner

@DHowett-MSFT commented on GitHub (Jun 11, 2019):

This seems worse since #825.

@DHowett-MSFT commented on GitHub (Jun 11, 2019): This seems worse since #825.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#1591