diff --git a/src/node_worker.cc b/src/node_worker.cc index 7369e13768e2d9..a510ea85731488 100644 --- a/src/node_worker.cc +++ b/src/node_worker.cc @@ -149,9 +149,7 @@ class WorkerThreadData { Isolate* isolate = Isolate::Allocate(); if (isolate == nullptr) { - // TODO(addaleax): This should be ERR_WORKER_INIT_FAILED, - // ERR_WORKER_OUT_OF_MEMORY is for reaching the per-Worker heap limit. - w->Exit(1, "ERR_WORKER_OUT_OF_MEMORY", "Failed to create new Isolate"); + w->Exit(1, "ERR_WORKER_INIT_FAILED", "Failed to create new Isolate"); return; } @@ -297,9 +295,7 @@ void Worker::Run() { TryCatch try_catch(isolate_); context = NewContext(isolate_); if (context.IsEmpty()) { - // TODO(addaleax): This should be ERR_WORKER_INIT_FAILED, - // ERR_WORKER_OUT_OF_MEMORY is for reaching the per-Worker heap limit. - Exit(1, "ERR_WORKER_OUT_OF_MEMORY", "Failed to create new Context"); + Exit(1, "ERR_WORKER_INIT_FAILED", "Failed to create new Context"); return; } }