Reproduction steps:
1. Open the attached project "CrashRepro"
2. Enter the Play mode
4. Focus a different window
5. Close the FolderBrowserDialog
6. Exit Play mode
7. Repeat from 2-6 until crash
Expected result: Editor exits Play mode
Actual result: Editor crashes
Reproducible with: 2022.2.0a1, 2022.3.44f1, 6000.0.17f1
Not reproducible with: 2021.3.42f1, 2022.1.0b1
Reproducible on: Windows 11
Not reproducible on: No other environment tested
Notes:
Reproduces very inconsistently
Sometimes crashes silently
Throws win32 error 487 on older editor versions (~below 2022.2.0b1)
First few lines of stack trace: