remove unloadPlatformBinary

This commit is contained in:
ConfiG 2024-01-15 00:41:00 +03:00
parent 12ba95f7ba
commit 5ff74e849a
No known key found for this signature in database
GPG key ID: 44DA1983F524C11B
3 changed files with 0 additions and 25 deletions
loader/src
loader
platform

View file

@ -63,7 +63,6 @@ namespace geode {
std::unordered_map<std::string, char const*> m_expandedSprites;
ModRequestedAction m_requestedAction = ModRequestedAction::None;
Impl(Mod* self, ModMetadata const& metadata);
@ -72,7 +71,6 @@ namespace geode {
Result<> setup();
Result<> loadPlatformBinary();
Result<> unloadPlatformBinary();
Result<> createTempDir();
// called on a separate thread

View file

@ -20,15 +20,3 @@ Result<> Mod::Impl::loadPlatformBinary() {
log::error("Unable to load the SO: dlerror returned ({})", err);
return Err("Unable to load the SO: dlerror returned (" + err + ")");
}
Result<> Mod::Impl::unloadPlatformBinary() {
auto so = m_platformInfo->m_so;
delete m_platformInfo;
m_platformInfo = nullptr;
if (dlclose(so) == 0) {
return Ok();
}
else {
return Err("Unable to free library");
}
}

View file

@ -68,14 +68,3 @@ Result<> Mod::Impl::loadPlatformBinary() {
}
return Err("Unable to load the DLL: " + getLastWinError());
}
Result<> Mod::Impl::unloadPlatformBinary() {
auto hmod = m_platformInfo->m_hmod;
delete m_platformInfo;
if (FreeLibrary(hmod)) {
return Ok();
}
else {
return Err("Unable to free the DLL: " + getLastWinError());
}
}