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
Hotpatch EZFRD64 to fix heap-related crashes, improve the UCRT patch #5582
Conversation
Source/Core/Common/Common.vcxproj
Outdated
| @@ -175,6 +176,7 @@ | |||
| <ClCompile Include="Hash.cpp" /> | |||
| <ClCompile Include="IniFile.cpp" /> | |||
| <ClCompile Include="JitRegister.cpp" /> | |||
| <ClCompile Include="LdrWatcher.cpp" /> | |||
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
Source/Core/Common/CompatPatches.cpp
Outdated
| auto parser = ModuleParser(event.base_address); | ||
| parser.PatchIAT("kernel32.dll", "HeapCreate", HeapCreateLow4GB); | ||
| } }); | ||
| } |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
| @@ -0,0 +1,121 @@ | |||
| #include <functional> | |||
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
Source/Core/Common/CompatPatches.h
Outdated
| @@ -0,0 +1,5 @@ | |||
| #pragma once | |||
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
| @@ -0,0 +1,176 @@ | |||
| #include <Windows.h> | |||
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
| @@ -0,0 +1,33 @@ | |||
| #pragma once | |||
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
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.
This is pretty much the same as the feedback I left before, but I suppose I'll leave it again since this PR has been created separately from the old one.
Source/Core/Common/CompatPatches.cpp
Outdated
| auto msg = StringFromFormat( | ||
| "You are running %S version %d.%d.%d.%d.\n" | ||
| "An important fix affecting dolphin was introduced in build %d.\n" | ||
| "You can use dolphin, but there will be known bugs.\n" |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
| event.name.c_str(), version.major, version.minor, version.build, | ||
| version.qfe, fixed_build); | ||
| // Use MessageBox for maximal user annoyance | ||
| MessageBoxA(nullptr, msg.c_str(), "WARNING: BUGGY UCRT VERSION", |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
| } | ||
| // If we reach here, the version is buggy (afaik) and patching failed | ||
| auto msg = StringFromFormat( | ||
| "You are running %S version %d.%d.%d.%d.\n" |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
Source/Core/Common/LdrWatcher.cpp
Outdated
|
|
||
| void LdrWatcher::Install(const LdrObserver& observer) | ||
| { | ||
| observers.emplace_back(std::move(observer)); |
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
This comment was marked as off-topic.
This comment was marked as off-topic.
Sorry, something went wrong.
…on drivers. Move ucrtFreadWorkaround to use the new LdrWatcher.
The PR should be complete. CMake didn't touch this before so meh.