Skip to content

Commit

Permalink
Maybe this will fix #808
Browse files Browse the repository at this point in the history
  • Loading branch information
mxcl committed Nov 18, 2023
1 parent 501573f commit 16c67d7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/utils/execve.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,9 @@ export class CStringArray extends Uint8Array {
// maximum bytes for a utf8 string is 4×length
stringsLength += string.length * 4 + 1;
}
super(8 * (strings.length + 1) + stringsLength);
// +1000 because we are getting macOS crashers we don’t understand and this is all
// we can think of that may cause it
super(8 * (strings.length + 1) + stringsLength + 1000);
const pointerBuffer = new BigUint64Array(this.buffer, 0, strings.length + 1);
const stringsBuffer = new Uint8Array(this.buffer).subarray(
(strings.length + 1) * 8,
Expand Down

0 comments on commit 16c67d7

Please sign in to comment.