domain: use strong reference to domain while active
When an uncaught exception is thrown inside a domain, the domain is removed from the stack as of 43a51708. This means that it might not be kept alive as an object anymore, and may be garbage collected before the `after()` hook can run, which tries to exit it as well. Resolve that by making references to the domain strong while it is active. Fixes: https://github.com/nodejs/node/issues/28275 PR-URL: https://github.com/nodejs/node/pull/28313 Reviewed-By:Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By:
Vladimir de Turckheim <vlad2t@hotmail.com> Reviewed-By:
Rich Trott <rtrott@gmail.com>
parent
49eb2b8e
Please register or sign in to comment