Win32 fixes.

This commit is contained in:
castano 2008-10-17 18:37:17 +00:00
parent 6d8a75462a
commit 7776bd5c17

View File

@ -15,7 +15,7 @@
void * nvLoadLibrary(const char * name)
{
#if NV_OS_WIN32
return LoadLibraryExA( name, NULL, 0 );
return (void *)LoadLibraryExA( name, NULL, 0 );
#else
return dlopen(name, RTLD_LAZY);
#endif
@ -25,7 +25,7 @@ void nvUnloadLibrary(void * handle)
{
nvDebugCheck(handle != NULL);
#if NV_OS_WIN32
FreeLibrary(handle);
FreeLibrary((HMODULE)handle);
#else
dlclose(handle);
#endif
@ -34,7 +34,7 @@ void nvUnloadLibrary(void * handle)
void * nvBindSymbol(void * handle, const char * symbol)
{
#if NV_OS_WIN32
return (void *)GetProcAddressA(handle, symbol);
return (void *)GetProcAddress((HMODULE)handle, symbol);
#else
return (void *)dlsym(handle, symbol);
#endif