Merge pull request #1272 from Frank-74/Remove-pjutilDynLibCallDllMain()
Remove pjutil::DynLibCallDllMain()
This commit is contained in:
commit
044eea5459
|
@ -49,20 +49,6 @@ void pjutil::DynLibClose(pjutil::DynLibHandle LibHandle)
|
|||
}
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
static void EmptyThreadFunction(void)
|
||||
{
|
||||
}
|
||||
|
||||
void pjutil::DynLibCallDllMain(void)
|
||||
{
|
||||
//jabo had a bug so I call CreateThread so the dllmain in the plugins will get called again with thread attached
|
||||
DWORD ThreadID;
|
||||
HANDLE hthread = CreateThread(NULL, 0, (LPTHREAD_START_ROUTINE)EmptyThreadFunction, NULL, 0, &ThreadID);
|
||||
CloseHandle(hthread);
|
||||
}
|
||||
#endif
|
||||
|
||||
void pjutil::Sleep(uint32_t timeout)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
|
|
|
@ -9,9 +9,6 @@ public:
|
|||
static DynLibHandle DynLibOpen(const char *pccLibraryPath, bool ShowErrors = true);
|
||||
static void * DynLibGetProc(DynLibHandle LibHandle, const char * ProcedureName);
|
||||
static void DynLibClose(DynLibHandle LibHandle);
|
||||
#ifdef _WIN32
|
||||
static void DynLibCallDllMain(void);
|
||||
#endif
|
||||
static void Sleep(uint32_t timeout);
|
||||
static bool TerminatedExistingExe();
|
||||
|
||||
|
@ -19,4 +16,4 @@ private:
|
|||
pjutil(void); // Disable default constructor
|
||||
pjutil(const pjutil&); // Disable copy constructor
|
||||
pjutil& operator=(const pjutil&); // Disable assignment
|
||||
};
|
||||
};
|
||||
|
|
|
@ -148,9 +148,6 @@ bool CAudioPlugin::Initiate(CN64System * System, RenderWindow * Window)
|
|||
m_Initialized = InitiateAudio(Info) != 0;
|
||||
|
||||
#ifdef _WIN32
|
||||
//jabo had a bug so I call CreateThread so his dllmain gets called again
|
||||
pjutil::DynLibCallDllMain();
|
||||
|
||||
if (System != NULL)
|
||||
{
|
||||
if (AiUpdate)
|
||||
|
|
|
@ -122,12 +122,6 @@ bool CControl_Plugin::Initiate(CN64System * System, RenderWindow * Window)
|
|||
m_Initialized = true;
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
//jabo had a bug so I call CreateThread so his dllmain gets called again
|
||||
pjutil::DynLibCallDllMain();
|
||||
#endif
|
||||
|
||||
return m_Initialized;
|
||||
}
|
||||
|
||||
|
|
|
@ -260,11 +260,6 @@ bool CGfxPlugin::Initiate(CN64System * System, RenderWindow * Window)
|
|||
WriteTrace(TraceGFXPlugin, TraceDebug, "Calling InitiateGFX");
|
||||
m_Initialized = InitiateGFX(Info) != 0;
|
||||
|
||||
#ifdef _WIN32
|
||||
//jabo had a bug so I call CreateThread so his dllmain gets called again
|
||||
pjutil::DynLibCallDllMain();
|
||||
#endif
|
||||
|
||||
WriteTrace(TraceGFXPlugin, TraceDebug, "Done (res: %s)", m_Initialized ? "true" : "false");
|
||||
return m_Initialized;
|
||||
}
|
||||
|
|
|
@ -352,10 +352,6 @@ bool CRSP_Plugin::Initiate(CPlugins * Plugins, CN64System * System)
|
|||
|
||||
m_Initialized = true;
|
||||
|
||||
#ifdef _WIN32
|
||||
//jabo had a bug so I call CreateThread so his dllmain gets called again
|
||||
pjutil::DynLibCallDllMain();
|
||||
#endif
|
||||
WriteTrace(TraceRSPPlugin, TraceDebug, "Done (res: %s)", m_Initialized ? "true" : "false");
|
||||
return m_Initialized;
|
||||
}
|
||||
|
@ -375,4 +371,4 @@ void CRSP_Plugin::ProcessMenuItem(int id)
|
|||
{
|
||||
m_RSPDebug.ProcessMenuItem(id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue