terminal/.github
Leonard Hecker ac265aab99
Fix TerminalControl crash on exit (#10031)
## Summary of the Pull Request

ControlCore's _renderer (IRenderTarget) is allocated as std::unique_ptr,
but is given to Terminal::CreateFromSettings as a reference.
ControlCore::Close deallocates the _renderer, but if ThrottledFuncs
are still scheduled to call ControlCore::UpdatePatternLocations
it'll cause Terminal::UpdatePatterns to be called, which in turn ends up
accessing the deallocated IRenderTarget reference and lead to a crash.

A proper solution with shared pointers is nontrivial and should be
attempted at a later point in time. This solution moves the teardown of
the _renderer into ControlCore::~ControlCore, where we can be certain
that no further strong references are held by ThrottledFuncs.

## PR Checklist
* [x] Closes #9910
* [x] I work here
* [x] Tests added/passed

## Validation Steps Performed

The crash is a race condition and inherently hard to reproduce.
During validation this PR didn't appear to introduce new crashes.
2021-05-04 21:17:37 +00:00
..
actions/spelling Fix TerminalControl crash on exit (#10031) 2021-05-04 21:17:37 +00:00
ISSUE_TEMPLATE Update the bug report template for 04-21 schema (#9961) 2021-04-26 17:06:12 -05:00
linters Add support for autodetecting URLs and making hyperlinks (#7691) 2020-10-28 20:24:43 +00:00
workflows ci: update to Spell check to 0.0.17a (#9014) 2021-02-03 11:17:38 -08:00
PULL_REQUEST_TEMPLATE.md Add schema check to PR template (#6599) 2020-06-19 12:06:23 -07:00