From 309ba47483840a616931122877c4e5d93d56aab9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Breitbart?= Date: Mon, 5 Dec 2022 20:03:25 +0100 Subject: [PATCH] change batch size to 500 --- src/common/buffer/Buffer.ts | 4 ++-- src/common/buffer/BufferLine.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/common/buffer/Buffer.ts b/src/common/buffer/Buffer.ts index 5ecf19bb..4f02e36d 100644 --- a/src/common/buffer/Buffer.ts +++ b/src/common/buffer/Buffer.ts @@ -269,9 +269,9 @@ export class Buffer implements IBuffer { let counted = 0; for (let i = 0; i < this.lines.length; i++) { counted += this.lines.get(i)!.cleanupMemory(); - // throttle to 5k lines at once and + // throttle to 500 lines at once and // return true to indicate, that the task is not finished yet - if (counted > 5000) { + if (counted > 500) { return true; } } diff --git a/src/common/buffer/BufferLine.ts b/src/common/buffer/BufferLine.ts index ac4ea768..d5f43844 100644 --- a/src/common/buffer/BufferLine.ts +++ b/src/common/buffer/BufferLine.ts @@ -340,8 +340,8 @@ export class BufferLine implements IBufferLine { * Resize BufferLine to `cols` filling excess cells with `fillCellData`. * The underlying array buffer will not change if there is still enough space * to hold the new buffer line data. - * Returns a boolean indicating, whether a `cleanBuffer` call would free - * excess memory (after shrinking > CLEANUP_THRESHOLD). + * Returns a boolean indicating, whether a `cleanupMemory` call would free + * excess memory (true after shrinking > CLEANUP_THRESHOLD). */ public resize(cols: number, fillCellData: ICellData): boolean { if (cols === this.length) {