Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
PowerShell menu completion parser thread-safety fix (#17221)
Fix Terminal crashing when experimental PowerShell menu completion is very quickly invoked multiple times. `Command::ParsePowerShellMenuComplete` can be called from multiple threads, but it uses a `static` `Json::CharReader`, which cannot safely parse data from multiple threads at the same time. Removing `static` fixes the problem, since every function call gets its own `reader`. Validation: Pressed Ctrl+Space quickly a few times with hardcoded huge JSON as the completion payload. Also shown at the end of the second video in #17220. Closes #17220
- Loading branch information