crlib: reworked dictionary to hashmap.
linkage: another fix to dynamic linkage. cpp: fixed msvc warning about placement new.
This commit is contained in:
parent
b70d2af4ab
commit
43f6a7828a
12 changed files with 291 additions and 312 deletions
|
|
@ -1161,21 +1161,21 @@ SharedLibrary::Handle EntityLinkage::lookup (SharedLibrary::Handle module, const
|
|||
if (self.handle () != module) {
|
||||
return resolve (module);
|
||||
}
|
||||
|
||||
if (m_exports.has (function)) {
|
||||
return m_exports[function];
|
||||
}
|
||||
auto botAddr = resolve (self.handle ());
|
||||
|
||||
if (!botAddr) {
|
||||
auto gameAddr = resolve (gamedll.handle ());
|
||||
|
||||
if (gameAddr) {
|
||||
m_exports[function] = gameAddr;
|
||||
return m_exports[function] = gameAddr;
|
||||
}
|
||||
}
|
||||
else {
|
||||
m_exports[function] = botAddr;
|
||||
}
|
||||
|
||||
if (m_exports.exists (function)) {
|
||||
return m_exports[function];
|
||||
return m_exports[function] = botAddr;
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue