mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-09-21 20:06:40 +00:00
Separate JS_ShutDown from the normal ScriptingHost shutdown, because it's resetting non-thread-safe per-process state.
DllLoader: Report dlerror when dlopen fails. AtlasObject: Avoid ICC warnings caused by 'const T' being equivalent to 'T' when 'T' is already const. This was SVN commit r5133.
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
|
||||
#include "lib/posix/posix_dlfcn.h"
|
||||
#include "ps/CStr.h"
|
||||
#include "ps/CLogger.h"
|
||||
|
||||
void* const HANDLE_UNAVAILABLE = (void*)-1;
|
||||
|
||||
@@ -65,7 +66,12 @@ bool DllLoader::LoadDLL()
|
||||
|
||||
// open failed (mostly likely SO not found)
|
||||
if (! m_Handle)
|
||||
{
|
||||
char* error = dlerror();
|
||||
if (error)
|
||||
LOG(ERROR, "", "dlopen error: %s", error);
|
||||
m_Handle = HANDLE_UNAVAILABLE;
|
||||
}
|
||||
}
|
||||
|
||||
return (m_Handle != HANDLE_UNAVAILABLE);
|
||||
|
||||
Reference in New Issue
Block a user