Flush writes on resize

Fixes #5597
This commit is contained in:
Daniel Imms
2026-01-09 05:25:22 -08:00
parent 729a670043
commit bf7c95b6cc
3 changed files with 55 additions and 0 deletions
+4
View File
@@ -176,6 +176,10 @@ export abstract class CoreTerminal extends Disposable implements ICoreTerminal {
x = Math.max(x, MINIMUM_COLS);
y = Math.max(y, MINIMUM_ROWS);
// Flush pending writes before resize to avoid race conditions where async
// writes are processed with incorrect dimensions
this._writeBuffer.flushSync();
this._bufferService.resize(x, y);
}