Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

try libnode.dll first in load_exe_hook #2834

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -41,7 +41,7 @@
"nan": "^2.14.2",
"require-inject": "^1.4.4",
"standard": "^14.3.4",
"tap": "^12.7.0"
"tap": "^16.3.4"
},
"scripts": {
"lint": "standard */*.js test/**/*.js",
Expand Down
4 changes: 3 additions & 1 deletion src/win_delay_load_hook.cc
Expand Up @@ -28,7 +28,9 @@ static FARPROC WINAPI load_exe_hook(unsigned int event, DelayLoadInfo* info) {
if (_stricmp(info->szDll, HOST_BINARY) != 0)
return NULL;

m = GetModuleHandle(NULL);
// try for libnode.dll to compat node.js that using 'vcbuild.bat dll'
m = GetModuleHandle("libnode.dll");
if (m == NULL) m = GetModuleHandle(NULL);
return (FARPROC) m;
}

Expand Down