Skip to content

Commit

Permalink
fix: remove hook of CreateProcessA() under cygwin
Browse files Browse the repository at this point in the history
  • Loading branch information
shunf4 committed Mar 4, 2020
1 parent ab2c0f0 commit 8b32049
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,7 @@ cygwin_build/**/MAKING_*
cygwin_build/**/distx*
cygwin_build/**/*.stackdump
cygwin_build/**/*.bin
cygwin_build/**/MADE_REMOTE_FUNC_BIN_HEADER

msys_build/**/*.d
msys_build/**/*.o
Expand All @@ -363,4 +364,5 @@ msys_build/**/*.stackdump
msys_build/**/*.bin

win32_output/
dist/
dist/
include/remote_func_bin*.h
1 change: 0 additions & 1 deletion include/remote_func_bin_x64d.h

This file was deleted.

1 change: 0 additions & 1 deletion include/remote_func_bin_x86d.h

This file was deleted.

2 changes: 2 additions & 0 deletions src/dll/hookdll_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,9 @@ PXCH_DLL_API DWORD __stdcall InitHook(PXCH_INJECT_REMOTE_DATA* pRemoteData)
if (PXCH_HOOK_CONDITION) {
MH_Initialize();

#ifndef __CYGWIN__ // Hooking CreateProcessA under cygwin causes CreateProcessW WinError 2.
CREATE_HOOK(CreateProcessA);
#endif
CREATE_HOOK(CreateProcessW);
// CREATE_HOOK(CreateProcessAsUserW);

Expand Down

0 comments on commit 8b32049

Please sign in to comment.