[PR #1326] [MERGED] CreateFile with the right flags #24577

Open
opened 2026-01-31 09:04:08 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/1326
Author: @zadjii-msft
Created: 6/19/2019
Status: Merged
Merged: 6/19/2019
Merged by: @undefined

Base: masterHead: dev/migrie/b/1325-hot-reload-explode


📝 Commits (1)

📊 Changes

1 file changed (+2 additions, -2 deletions)

View changed files

📝 src/cascadia/TerminalApp/CascadiaSettingsSerialization.cpp (+2 -2)

📄 Description

We need FILE_SHARE_READ | FILE_SHARE_WRITE on both calls to CreateFile, so that we can properly watch the file for reloads.

Without these, when the file reloaded, we'd fail to open the file, think that it's because the file doesn't exist, create the default settings, and then we'd blow away the user's settings.

Fixes #1325


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/1326 **Author:** [@zadjii-msft](https://github.com/zadjii-msft) **Created:** 6/19/2019 **Status:** ✅ Merged **Merged:** 6/19/2019 **Merged by:** [@undefined](undefined) **Base:** `master` ← **Head:** `dev/migrie/b/1325-hot-reload-explode` --- ### 📝 Commits (1) - [`7782583`](https://github.com/microsoft/terminal/commit/77825833c79c7205dc99efe1b4f259ee65978928) fix this bug ### 📊 Changes **1 file changed** (+2 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/TerminalApp/CascadiaSettingsSerialization.cpp` (+2 -2) </details> ### 📄 Description We need `FILE_SHARE_READ | FILE_SHARE_WRITE` on _both_ calls to `CreateFile`, so that we can properly watch the file for reloads. Without these, when the file reloaded, we'd fail to open the file, think that it's because the file doesn't exist, create the default settings, and then we'd blow away the user's settings. Fixes #1325 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:04:08 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#24577