Remove "failed to preload executable" print on Linux and MacOS (#80)

This commit is contained in:
Reonu
2026-01-15 23:44:13 +00:00
committed by GitHub
parent 40f95cec35
commit 5a720ff962
+14 -2
View File
@@ -513,13 +513,25 @@ void release_preload(PreloadContext& context) {
context = {};
}
#else
#elif defined(__linux__) || defined(APPLE)
struct PreloadContext {
};
// TODO implement on other platforms
bool preload_executable(PreloadContext& context) {
// Preloading isn't implemented on Linux and MacOS, but it's also unnecessary there, as the OS already preloads the executable.
// Therefore, we can just consider the executable to be preloaded.
return true;
}
void release_preload(PreloadContext& context) {
}
#else
struct PreloadContext {};
bool preload_executable(PreloadContext& context) {
return false;
}