[PR #2924] [MERGED] Patch fix for #1360 until WriteStream (#780) can be implemented. #25149

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

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/2924
Author: @miniksa
Created: 9/26/2019
Status: ✅ Merged
Merged: 10/1/2019
Merged by: @undefined

Base: master ← Head: dev/miniksa/1360


📝 Commits (4)

  • f60566c Patch fix for #1360 until WriteStream (#780) can be implemented.
  • f92666f Add a test that hangs in the broken state and passes in the success stat. Writes a bisecting character to the right most cell in the window.
  • a1fcbc4 Code format! shakes fist at sky
  • dfa4fb9 Update src/cascadia/TerminalCore/Terminal.cpp

📊 Changes

3 files changed (+106 additions, -1 deletions)

View changed files

📝 src/cascadia/TerminalCore/Terminal.cpp (+12 -0)
➕ src/cascadia/UnitTests_TerminalCore/TerminalApiTests.cpp (+92 -0)
📝 src/cascadia/UnitTests_TerminalCore/UnitTests.vcxproj (+2 -1)

📄 Description

Summary of the Pull Request

Writing can enter an infinite loop with full-width characters being inserted into the last column of the buffer.

References

#780

PR Checklist

Detailed Description of the Pull Request / Additional comments

This is because the "WriteCharsLegacy2ElectricBoogaloo" implementation in the Terminal (Terminal::_WriteBuffer) is a hacky thing that we put together knowing full well that we'd have to do #780 but we had to get this working enough for now. Turns out, it's not super complete and fragile. Surprise.

Validation Steps Performed

  • Manual run of @treit's sample against the Terminal.
  • Attempting to author automated test with @treit's sample
  • I need to run it against conhost and make sure it's not failing too (and fix it there too if it is)

🔄 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/2924 **Author:** [@miniksa](https://github.com/miniksa) **Created:** 9/26/2019 **Status:** ✅ Merged **Merged:** 10/1/2019 **Merged by:** [@undefined](undefined) **Base:** `master` ← **Head:** `dev/miniksa/1360` --- ### 📝 Commits (4) - [`f60566c`](https://github.com/microsoft/terminal/commit/f60566c46a4987b11a06ee337311c48bcc59269a) Patch fix for #1360 until WriteStream (#780) can be implemented. - [`f92666f`](https://github.com/microsoft/terminal/commit/f92666fe7eca6a070d451d48e6742964b3bec4dc) Add a test that hangs in the broken state and passes in the success stat. Writes a bisecting character to the right most cell in the window. - [`a1fcbc4`](https://github.com/microsoft/terminal/commit/a1fcbc468413d8bb198e673dc833440c5fecc0de) Code format! *shakes fist at sky* - [`dfa4fb9`](https://github.com/microsoft/terminal/commit/dfa4fb9568052ef716ded33d5c2dc2fa68d29419) Update src/cascadia/TerminalCore/Terminal.cpp ### 📊 Changes **3 files changed** (+106 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/TerminalCore/Terminal.cpp` (+12 -0) ➕ `src/cascadia/UnitTests_TerminalCore/TerminalApiTests.cpp` (+92 -0) 📝 `src/cascadia/UnitTests_TerminalCore/UnitTests.vcxproj` (+2 -1) </details> ### 📄 Description <!-- Enter a brief description/summary of your PR here. What does it fix/what does it change/how was it tested (even manually, if necessary)? --> ## Summary of the Pull Request Writing can enter an infinite loop with full-width characters being inserted into the last column of the buffer. <!-- Other than the issue solved, is this relevant to any other issues/existing PRs? --> ## References #780 <!-- Please review the items on the PR checklist before submitting--> ## PR Checklist * [X] Closes #1360 * [X] I work here * [ ] Draft because I'm going to try to turn the code @treit gave me for repro into a test * [X] Documented by comments at the hack and noted for #780 * [X] I'm a core contributor <!-- Provide a more detailed description of the PR, other things fixed or any additional comments/features here --> ## Detailed Description of the Pull Request / Additional comments This is because the "WriteCharsLegacy2ElectricBoogaloo" implementation in the Terminal (`Terminal::_WriteBuffer`) is a hacky thing that we put together knowing full well that we'd have to do #780 but we had to get this working enough for now. Turns out, it's not super complete and fragile. Surprise. <!-- Describe how you validated the behavior. Add automated tests wherever possible, but list manual validation steps taken as well --> ## Validation Steps Performed - Manual run of @treit's sample against the Terminal. - Attempting to author automated test with @treit's sample - I need to run it against conhost and make sure it's not failing too (and fix it there too if it is) --- <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:07:36 +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#25149