Remove dynamic loading of AttachConsole.
API is available since WinXP.
This commit is contained in:
@@ -377,10 +377,7 @@ bool wxConsoleStderr::DoInit()
|
|||||||
if ( !m_dllKernel32.Load(wxT("kernel32.dll")) )
|
if ( !m_dllKernel32.Load(wxT("kernel32.dll")) )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
typedef BOOL (WINAPI *AttachConsole_t)(DWORD dwProcessId);
|
if ( !::AttachConsole(ATTACH_PARENT_PROCESS) )
|
||||||
AttachConsole_t wxDL_INIT_FUNC(pfn, AttachConsole, m_dllKernel32);
|
|
||||||
|
|
||||||
if ( !pfnAttachConsole || !pfnAttachConsole(ATTACH_PARENT_PROCESS) )
|
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// console attached, set m_hStderr now to ensure that we free it in the
|
// console attached, set m_hStderr now to ensure that we free it in the
|
||||||
|
Reference in New Issue
Block a user