Use the same function for logging dynlib errors on all platforms
Reduces the amount of #ifdefs scattered all over the code, thereby simplifying the code. The function was renamed from Error() to ReportError() to emphasize what its purpose is. Error messages logged on *nix are now a bit more verbose, as they are prefixed with our own description text, which were earlier omitted on platforms using the dlxxx() API.
This commit is contained in:
@@ -357,11 +357,9 @@ protected:
|
||||
// common part of GetSymbol() and HasSymbol()
|
||||
void* DoGetSymbol(const wxString& name, bool* success = NULL) const;
|
||||
|
||||
#ifdef HAVE_DLERROR
|
||||
// log the error after a dlxxx() function failure
|
||||
static void Error();
|
||||
#endif // HAVE_DLERROR
|
||||
|
||||
// log the error after an OS dynamic library function failure
|
||||
static void ReportError(const wxString& msg,
|
||||
const wxString& name = wxString());
|
||||
|
||||
// the handle to DLL or NULL
|
||||
wxDllType m_handle;
|
||||
|
Reference in New Issue
Block a user