-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
mingw: use CreateHardLink directly #1334
mingw: use CreateHardLink directly #1334
Conversation
The upstream has some older version of this which would conflict, I'll submit the cleanup there as well |
compat/mingw.c
Outdated
@@ -2,6 +2,7 @@ | |||
#include "win32.h" | |||
#include <conio.h> | |||
#include <wchar.h> | |||
#include <windows.h> |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
Thank you! As I pointed out, this should compile correctly without the extra Thanks! |
Oh, and if you could sign off on the patch? I need that to be able to submit this same patch upstream after cooking it in Git for Windows for a while. |
9ac5f33
to
99f0c95
Compare
It was observed that the current implementation of of get_proc_addr() fails to load the kernel32.dll with code ERROR_INVALID_PARAMETER. Probably the reason is that kernel32.dll is already loaded. The behavior was seen at Windows SP1, both 32bit and 64bit. Probably it would behave same way in some or all other Windows versions. This breaks all usages of "clone --local", including the automatic tests where they call it. The function CreateHardLink is available in all supported Windows versions (since Windows XP), so there is no more need to resolve it in runtime. Signed-off-by: Max Kirillov <[email protected]>
99f0c95
to
e9630ae
Compare
I have updated the commit. It build and passes at least some tests. Runnig full suite now but I expect it to be ok |
Perfect, thanks! |
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
…teHardLinkW mingw: use CreateHardLink directly
…teHardLinkW mingw: use CreateHardLink directly
…teHardLinkW mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
…teHardLinkW mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
…teHardLinkW mingw: use CreateHardLink directly
…teHardLinkW mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
…teHardLinkW mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
mingw: use CreateHardLink directly
It was observed that the current implementation of of get_proc_addr()
fails to load the kernel32.dll with code ERROR_INVALID_PARAMETER.
Probably the reason is that kernel32.dll is already loaded. The
behavior was seen at Windows SP1, both 32bit and 64bit. Probably it
would behave same way in some or all other Windows versions.
This breaks all usages of "clone --local", including the automatic
tests where they call it.
The function CreateHardLink is available in all supported Windows
versions (since Windows XP), so there is no more need to resolve it
in runtime.