Update loader.c to add ABI Mismatch Warning for NVIDIA Driver

makes the -IgnoreABI flag assumed and adds a new warning in logs to show ABI mismatch. It warns in the log of the mismatch and returns true instead of killing X with this modification. It is unknown how long the latest nvidia driver will continue working with IgnoreABI, but I think its a worthy feature to add in the interm of a better solution.
This commit is contained in:
Collin 2025-06-26 18:58:51 -05:00 committed by GitHub
parent 3e1c2d5456
commit 45b1e6e0bb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -157,7 +157,14 @@ LoaderSetOptions(unsigned long opts)
Bool
LoaderShouldIgnoreABI(void)
{
return (LoaderOptions & LDR_OPT_ABI_MISMATCH_NONFATAL) != 0;
LogMessage(X_WARNING,
"ABI mismatch detected possibly from an NVIDIA driver. Attempting to continue loading X...\n"
"Expected ABI versions: ANSIC=%d, VideoDriver=%d, XInput=%d, Extension=%d\n",
LoaderVersionInfo.ansicVersion,
LoaderVersionInfo.videodrvVersion,
LoaderVersionInfo.xinputVersion,
LoaderVersionInfo.extensionVersion);
return TRUE;
}
int