X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/609533d54db83ee9d85fe7ad9589521fcf3f6be1..56fc3fa5b3be585a27af0ac3263350e16c992e41:/src/common/dynlib.cpp diff --git a/src/common/dynlib.cpp b/src/common/dynlib.cpp index 185e81661f..167249ab20 100644 --- a/src/common/dynlib.cpp +++ b/src/common/dynlib.cpp @@ -222,7 +222,7 @@ bool wxDynamicLibrary::Load(wxString libname, int flags) #elif defined(HAVE_DLOPEN) || defined(__DARWIN__) #if defined(__VMS) || defined(__DARWIN__) - m_handle = dlopen(libname.c_str(), 0); // The second parameter is ignored + m_handle = dlopen(libname.fn_str(), 0); // The second parameter is ignored #else // !__VMS && !__DARWIN__ int rtldFlags = 0; @@ -326,14 +326,15 @@ void *wxDynamicLibrary::GetSymbol(const wxString &name, bool *success) const bool failed = FALSE; void *symbol = 0; + wxUnusedVar(symbol); #if defined(__WXMAC__) && !defined(__DARWIN__) Ptr symAddress; CFragSymbolClass symClass; Str255 symName; #if TARGET_CARBON - c2pstrcpy( (StringPtr) symName, name ); + c2pstrcpy( (StringPtr) symName, name.fn_str() ); #else - strcpy( (char *)symName, name ); + strcpy( (char *)symName, name.fn_str() ); c2pstr( (char *)symName ); #endif if( FindSymbol( m_handle, symName, &symAddress, &symClass ) == noErr ) @@ -353,7 +354,11 @@ void *wxDynamicLibrary::GetSymbol(const wxString &name, bool *success) const symbol = 0; #elif defined(__WINDOWS__) +#ifdef __WXWINCE__ + symbol = (void*) ::GetProcAddress( m_handle, name ); +#else symbol = (void*) ::GetProcAddress( m_handle, name.mb_str() ); +#endif #else #error "runtime shared lib support not implemented"