microsoft / microsoft/terminal
Duplicate remainingProfiles in newTabMenu causes crash (Access Violation in Settings.Model.dll)
- Dominant language
- C++
- Stars
- 105k
- Forks
- 9.6k
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 29
Description
### Windows Terminal version
1.24.10921.0
### Windows build number
10.0.26200.8246
### Other Software
N/A - this is a settings parser issue, no other software involved
### Steps to reproduce
1. Open `%LOCALAPPDATA%\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState\settings.json`
2. Add a `newTabMenu` folder entry containing two consecutive `{"type": "remainingProfiles"}` entries:
```json
"newTabMenu": [
{
"allowEmpty": false,
"entries": [
{"icon": null, "profile": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}", "type": "profile"},
{"type": "remainingProfiles"},
{"type": "remainingProfiles"}
],
"icon": null,
"inline": "never",
"name": "Other",
"type": "folder"
}
]
```
3. Save and launch `wt.exe`
### Expected Behavior
Terminal should either ignore the duplicate `remainingProfiles` entry and launch normally, or display a settings validation error and fall back to default settings (like it does for JSON syntax errors).
### Actual Behavior
Terminal crashes silently on every launch attempt. No error dialog is shown. Running `wt.exe` from cmd.exe produces no output. The process starts briefly then terminates.
Event Viewer shows:
Faulting module: Microsoft.Terminal.Settings.Model.dll (version 1.24.2604.2001)
Exception code: 0xc0000005 (Access Violation)
Fault offset: 0x0000000000137e1b
The crash occurs at the same offset every time, consistent with a null pointer dereference in the settings model parser.
Root cause was isolated by binary-search bisection of settings.json -- all other sections (profiles, actions, keybindings, schemes, top-level settings) work fine. Only the duplicate `remainingProfiles` triggers the crash.
The duplicate entry was introduced through the Windows Terminal settings UI while configuring the newTabMenu folder structure. This means the UI itself generates a configuration that crashes the parser on next launch, with no way to recover except manually editing settings.json.
Contributor guide
Assessment
This issue has not been assessed yet.