mirror of
https://github.com/nodejs/node.git
synced 2025-05-07 15:35:41 +00:00

When console.log is called for the first time it initializes TTYWrap object. However, if there is not enough space on the V8 stack, creating function template fails and triggers empty maybe local exception. PR-URL: https://github.com/nodejs/node/pull/26832 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
21 lines
361 B
JavaScript
21 lines
361 B
JavaScript
'use strict';
|
|
const common = require('../common');
|
|
|
|
// This test ensures that console.log
|
|
// will not crash the process if there
|
|
// is not enough space on the V8 stack
|
|
|
|
const done = common.mustCall(() => {});
|
|
|
|
async function test() {
|
|
await test();
|
|
}
|
|
|
|
(async () => {
|
|
try {
|
|
await test();
|
|
} catch (err) {
|
|
console.log(err);
|
|
}
|
|
})().then(done, done);
|