-
Notifications
You must be signed in to change notification settings - Fork 33
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
Workaround certain anti-malware programs #37
Conversation
8d105b8
to
d3507f2
Compare
A couple of comments:
|
Will do.
You mean 0x210040000? Random choice. If you have any scientific-like idea to get a new base address, my ears are wide open. The only semi-feasible approach imho would be to take a windows install and query all the base addresses of all the exe/dll's and then choose something that's not there, but still...
I confirm it seems to work. I managed to get
|
Ok, even rebasing EDIT: since the CI build doesn't come with many complex programs, I simply dropped |
This might break things, but it turns out several Windows libraries like to be loaded at 0x180000000. This causes a problem, because `msys-2.0.dll` loads at `0x180040000` and expects `0x180000000-0x180040000` to be available. A problem arises when Antiviruses (or other DLL hooking mechanisms) load a DLL whose preferred load address is `0x180000000` and fits in size before `0x180010000`: 1. `msys-2.0.dll` loads and fills `0x180010000-0x180040000` assuming no shared console structure is going to be needed. 2. Another DLL loads and fills `0x180000000-0x18000xxxx` 3. `msys-2.0.dll` tries to load `0x180000000-0x180010000` but it's not available. It falls back to another address, but down the line something else fails. This bug triggers when using subshells (e.g.: `git clone --recursive`). The MSYS2 runtime should be able to work around the address conflict, but the code is failing in some way or other... Signed-off-by: Johannes Schindelin <[email protected]> Signed-off-by: Mikael Larsson <[email protected]>
@orgads since you have access to Windows 7, could I trouble you to test this? |
Sure, I'll test it tomorrow. |
Works for me on Win7. No crash on |
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Thank you @chirpnot! |
Many anti-malware products seem to have problems with our MSYS2 runtime, leading to problems running e.g. `git subtree`. We [added a workaround](git-for-windows/msys2-runtime#37) that hopefully helps in most of these scenarios. Signed-off-by: Johannes Schindelin <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
K
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
Workaround certain anti-malware programs Signed-off-by: Johannes Schindelin <[email protected]>
This might break things, but it turns out several Windows libraries like to be loaded at 0x180000000.
This causes a problem, because
msys-2.0.dll
loads at0x180040000
and expects0x180000000-0x180040000
to be available.A problem arises when Antiviruses (or other DLL hooking mechanisms) load a dll whose preferred load address is
0x180000000
and fits in size before0x180010000
:msys-2.0.dll
loads and fills0x180010000-0x180040000
assuming no shared console structure is going to be needed.0x180000000-0x18000xxxx
msys-2.0.dll
tries to load0x180000000-0x180010000
but it's not available. It falls back to another address, but down the line something else fails.This bug triggers when using subshells (e.g.:
git clone --recursive
).(I guess msys should be able to work around the address conflict, but the code is failing in some way and I'm having a hard time figuring it out, so...)
This addresses git-for-windows/git#3539