dont miss this

This commit is contained in:
Alistair Smith
2025-06-05 14:27:22 -07:00
parent 8143c0690c
commit 975caa75b1

View File

@@ -282,7 +282,7 @@ fn setCwd_(globalObject: *jsc.JSGlobalObject, to: *jsc.ZigString) bun.JSError!js
// TODO(@190n) this may need to be noreturn
pub fn exit(globalObject: *jsc.JSGlobalObject, code: u8) callconv(.c) void {
var vm = globalObject.bunVM();
vm.exit_handler.exit_code = code;
vm.exit_handler.exit_code = code; // TODO(@alii) Is setting this multiple times incorrect? There's a regression node test for this (https://linear.app/oven/issue/BUN-13917/nodejs-test-test-worker-process-exit-async-modulejs)
if (vm.worker) |worker| {
// TODO(@190n) we may need to use requestTerminate or throwTerminationException
// instead to terminate the worker sooner