avoid-crash-16k-page-size.patch 706 B

1234567891011121314151617
  1. diff --git a/src/main.ts b/src/main.ts
  2. index c132c9b..51a7290 100644
  3. --- a/src/main.ts
  4. +++ b/src/main.ts
  5. @@ -524,2 +524,12 @@ function getJSFlags(cliArgs: NativeParsedArgs): string | null {
  6. + // Fix cppgc crash on Linux with 16KB page size.
  7. + // Refs https://issues.chromium.org/issues/378017037
  8. + // The fix from https://github.com/electron/electron/commit/6c5b2ef55e08dc0bede02384747549c1eadac0eb
  9. + // only affects non-renderer process.
  10. + // The following will ensure that the flag will be
  11. + // applied to the renderer process as well.
  12. + // TODO: Remove this once we update to
  13. + // Chromium >= 134.
  14. + jsFlags.push('--nodecommit_pooled_pages');
  15. +
  16. return jsFlags.length > 0 ? jsFlags.join(' ') : null;