Skip to content

Commit 0d928d7

Browse files
committed
fixup! src: allow blobs in addition to FILE*s in embedder snapshot API
1 parent 56170f5 commit 0d928d7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

test/embedding/embedtest.cc

+4-2
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,8 @@ int RunNodeInstance(MultiIsolatePlatform* platform,
8787
snapshot = node::EmbedderSnapshotData::FromBlob(vec);
8888
}
8989
assert(snapshot);
90-
fclose(fp);
90+
int ret = fclose(fp);
91+
assert(ret == 0);
9192
}
9293

9394
std::vector<std::string> errors;
@@ -149,7 +150,8 @@ int RunNodeInstance(MultiIsolatePlatform* platform,
149150
size_t written = fwrite(vec.data(), vec.size(), 1, fp);
150151
assert(written == 1);
151152
}
152-
fclose(fp);
153+
int ret = fclose(fp);
154+
assert(ret == 0);
153155
}
154156

155157
node::Stop(env);

0 commit comments

Comments
 (0)