mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-08-28 09:31:36 +00:00
Updated source to match SDL function prototype style
This commit is contained in:
@@ -34,8 +34,7 @@
|
||||
#include "../../video/uikit/SDL_uikitvideo.h"
|
||||
#endif
|
||||
|
||||
void *
|
||||
SDL_LoadObject(const char *sofile)
|
||||
void *SDL_LoadObject(const char *sofile)
|
||||
{
|
||||
void *handle;
|
||||
const char *loaderror;
|
||||
@@ -55,8 +54,7 @@ SDL_LoadObject(const char *sofile)
|
||||
return handle;
|
||||
}
|
||||
|
||||
void *
|
||||
SDL_LoadFunction(void *handle, const char *name)
|
||||
void *SDL_LoadFunction(void *handle, const char *name)
|
||||
{
|
||||
void *symbol = dlsym(handle, name);
|
||||
if (symbol == NULL) {
|
||||
|
||||
@@ -27,16 +27,14 @@
|
||||
|
||||
#include "SDL_loadso.h"
|
||||
|
||||
void *
|
||||
SDL_LoadObject(const char *sofile)
|
||||
void *SDL_LoadObject(const char *sofile)
|
||||
{
|
||||
const char *loaderror = "SDL_LoadObject() not implemented";
|
||||
SDL_SetError("Failed loading %s: %s", sofile, loaderror);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void *
|
||||
SDL_LoadFunction(void *handle, const char *name)
|
||||
void *SDL_LoadFunction(void *handle, const char *name)
|
||||
{
|
||||
const char *loaderror = "SDL_LoadFunction() not implemented";
|
||||
SDL_SetError("Failed loading %s: %s", name, loaderror);
|
||||
|
||||
@@ -32,8 +32,7 @@
|
||||
#define INCL_DOSERRORS
|
||||
#include <os2.h>
|
||||
|
||||
void *
|
||||
SDL_LoadObject(const char *sofile)
|
||||
void *SDL_LoadObject(const char *sofile)
|
||||
{
|
||||
ULONG ulRC;
|
||||
HMODULE hModule;
|
||||
@@ -65,8 +64,7 @@ SDL_LoadObject(const char *sofile)
|
||||
return (void *)hModule;
|
||||
}
|
||||
|
||||
void *
|
||||
SDL_LoadFunction(void *handle, const char *name)
|
||||
void *SDL_LoadFunction(void *handle, const char *name)
|
||||
{
|
||||
ULONG ulRC;
|
||||
PFN pFN;
|
||||
@@ -90,8 +88,7 @@ SDL_LoadFunction(void *handle, const char *name)
|
||||
return (void *)pFN;
|
||||
}
|
||||
|
||||
void
|
||||
SDL_UnloadObject(void *handle)
|
||||
void SDL_UnloadObject(void *handle)
|
||||
{
|
||||
if (handle != NULL) {
|
||||
DosFreeModule((HMODULE)handle);
|
||||
|
||||
@@ -29,8 +29,7 @@
|
||||
|
||||
#include "SDL_loadso.h"
|
||||
|
||||
void *
|
||||
SDL_LoadObject(const char *sofile)
|
||||
void *SDL_LoadObject(const char *sofile)
|
||||
{
|
||||
void *handle;
|
||||
LPTSTR tstr;
|
||||
@@ -61,8 +60,7 @@ SDL_LoadObject(const char *sofile)
|
||||
return handle;
|
||||
}
|
||||
|
||||
void *
|
||||
SDL_LoadFunction(void *handle, const char *name)
|
||||
void *SDL_LoadFunction(void *handle, const char *name)
|
||||
{
|
||||
void *symbol = (void *)GetProcAddress((HMODULE)handle, name);
|
||||
if (symbol == NULL) {
|
||||
|
||||
Reference in New Issue
Block a user