From aa1294766ca53abab6050a9080e4e662dacc76bb Mon Sep 17 00:00:00 2001 From: Harry Nguyen Date: Mon, 6 May 2024 08:18:22 +0700 Subject: [PATCH] fix: value for flag --max-old-space-size=-1 of type size_t is out of bounds [int] --- src/MemoryManager.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/MemoryManager.js b/src/MemoryManager.js index d49df02..3797800 100644 --- a/src/MemoryManager.js +++ b/src/MemoryManager.js @@ -21,9 +21,7 @@ export class MemoryManager { #init(nexusConfig) { this.memoryLimit = nexusConfig.getNested(NexusPropertiesConstants.MEMORY_LIMIT); - if (this.memoryLimit <= 0) { - Process.setMemoryLimit(-1); - } else { + if (this.memoryLimit > 0) { Process.setMemoryLimit(this.memoryLimit); } }