Content-Length: 257194 | pFad | https://github.com/nodejs/node/commit/500f3ccc66

8B src: lock the thread properly in snapshot builder · nodejs/node@500f3cc · GitHub
Skip to content

Commit 500f3cc

Browse files
joyeecheungmarco-ippolito
authored andcommitted
src: lock the thread properly in snapshot builder
Otherwise it can crash DCHECK when V8 expects that at least someone is locking the current thread. PR-URL: #56327 Fixes: nodejs/node-v8#294 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: Minwoo Jung <nodecorelab@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
1 parent 589d0ae commit 500f3cc

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/node_snapshotable.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -982,6 +982,8 @@ ExitCode BuildSnapshotWithoutCodeCache(
982982
}
983983

984984
Isolate* isolate = setup->isolate();
985+
v8::Locker locker(isolate);
986+
985987
{
986988
HandleScope scope(isolate);
987989
TryCatch bootstrapCatch(isolate);

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/nodejs/node/commit/500f3ccc66

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy