mirror of
https://github.com/nodejs/node.git
synced 2026-11-09 15:11:11 -05:00
src: fix duplication of externalized builtin code
The `else` here was missing, causing us to append the file to its existing `source` already in the map. Refs: https://github.com/nodejs/node/pull/45942 PR-URL: https://github.com/nodejs/node/pull/47079 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
This commit is contained in:
1 parent
d51541b720
commit
c3537ae8cc
1 file changed
+1
-2
@@ -224,8 +224,7 @@ void BuiltinLoader::AddExternalizedBuiltin(const char* id,
|
||||
auto it = externalized_builtin_sources.find(id);
|
||||
if (it != externalized_builtin_sources.end()) {
|
||||
source = it->second;
|
||||
}
|
||||
{
|
||||
} else {
|
||||
int r = ReadFileSync(&source, filename);
|
||||
if (r != 0) {
|
||||
fprintf(stderr,
|
||||
|
||||
Reference in new issue
Block a user