Skip to content

Commit 8209a15

Browse files
authored
Disable node snapshots (#245)
A security fix in V8 makes it impossible to put FunctionTemplateInfo objects of API functions with fast API callbacks into the snapshot. As Node.js does that so far, this PR disables node snapshots. In the future, FunctionTemplateInfo objects without fast API callbacks could be added back to the snapshot.
1 parent a9ce198 commit 8209a15

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

‎node.gni‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,12 @@ declare_args() {
6868
# TODO(zcbenz): There are few broken things for now:
6969
# 1. cross-os compilation is not supported.
7070
# 2. node_mksnapshot crashes when cross-compiling for x64 from arm64.
71-
node_use_node_snapshot = (host_os == target_os) && !(host_cpu == "arm64" && target_cpu == "x64")
71+
# node_use_node_snapshot = (host_os == target_os) && !(host_cpu == "arm64" && target_cpu == "x64")
72+
73+
# Disable snapshot for now. Node.js currently puts `FunctionTemplateInfo`
74+
# objects into the snapshot, but that only works for `FunctionTemplateInfo`
75+
# objects of API functions that do not support fast API calls.
76+
node_use_node_snapshot = false
7277

7378
# Build with Amaro (TypeScript utils).
7479
node_use_amaro = true

0 commit comments

Comments
 (0)