Fix Wine/Proton integrity violation crash in loader (MainFunctions.cpp)#5061
Open
DateFTP wants to merge 1 commit into
Open
Fix Wine/Proton integrity violation crash in loader (MainFunctions.cpp)#5061DateFTP wants to merge 1 commit into
DateFTP wants to merge 1 commit into
Conversation
When running under Wine/Proton on Linux, the anticheat module (netc.dll) detects Wine via wine_get_version in ntdll.dll and triggers a fail-fast exception (0xC0000409). The loader interprets this as an integrity violation and blocks startup. Changes in Client/loader/MainFunctions.cpp: - Set MTA_UNDER_WINE environment variable before launching GTA so child processes (loader-proxy, core.dll, netc.dll) can detect Wine and adjust behavior. - Skip the hardcoded MD5 file hash integrity check under Wine. System DLLs like D3DX9_42.dll, d3dcompiler_*.dll provided by Wine may have different hashes, causing false positives. This is the first step toward full Wine compatibility. loader-proxy/main.cpp should also be updated to hide the wine_get_version export before loading netc.dll.
Author
|
What this fix is for: Linux players are facing errors when launching the client, and there is an error with a integrity violation. I am further investigating the client for any issues with launching it through Wine. |
Author
|
It requires a lot of research, and I started getting an error with the GTA SA process, which failed to start the process correctly during testing. I need to check the details. |
Author
|
I am not sending the project for merging, as the loader requires additional work. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #4783
Problem:
Under Wine/Proton on Linux, MTA:SA crashes at startup with integrity violation error.
Additional issue: hardcoded MD5 file hash check compares system DLLs (D3DX9_42.dll, d3dcompiler_*.dll) which differ under Wine, causing false positives.
Changes in Client/loader/MainFunctions.cpp:
Checklist