From eb71aa0d04d91d3463981e6ff304282c6f482087 Mon Sep 17 00:00:00 2001 From: scarab Date: Mon, 28 Jul 2008 21:54:04 +0000 Subject: - nove nastaveni pro klavesy (not yet complete), smazte keyconfig - par uprav pro win32 (ve stejnem stavu jako predchozi) git-svn-id: http://opensvn.csie.org/tuxanci_ng@177 0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e --- src/base/exportFunction.c | 1 - src/base/exportFunction.h | 1 + src/base/modules.c | 4 +--- src/base/modules.h | 8 ++++++++ 4 files changed, 10 insertions(+), 4 deletions(-) (limited to 'src/base') diff --git a/src/base/exportFunction.c b/src/base/exportFunction.c index 955c0e1..550e4ec 100644 --- a/src/base/exportFunction.c +++ b/src/base/exportFunction.c @@ -37,7 +37,6 @@ void initExortFunction() { listExportFce = newList(); } - void addToExportFce(char *name, void *function) { printf("add to export function %s\n", name); diff --git a/src/base/exportFunction.h b/src/base/exportFunction.h index 5f3f1d0..8e01fc9 100644 --- a/src/base/exportFunction.h +++ b/src/base/exportFunction.h @@ -5,6 +5,7 @@ extern void initExortFunction(); extern void addToExportFce(char *name, void *function); + extern void* getExportFce(char *name); extern void quitExportFunction(); diff --git a/src/base/modules.c b/src/base/modules.c index e84cd30..13b0ff2 100755 --- a/src/base/modules.c +++ b/src/base/modules.c @@ -88,9 +88,8 @@ static void* getFce(module_t *p, char *s) static void* mapImage(char *name) { - void *image; - #ifndef __WIN32__ + void *image; image = dlopen (name, RTLD_LAZY); if( image == NULL ) @@ -118,7 +117,6 @@ static void* mapImage(char *name) ); fputs(msg, stderr); free(msg); - free(ret); FreeLibrary(image); return NULL; } diff --git a/src/base/modules.h b/src/base/modules.h index 8036a6a..5ad0287 100644 --- a/src/base/modules.h +++ b/src/base/modules.h @@ -31,7 +31,11 @@ typedef struct export_fce_s int (*fce_getNetTypeGame)(); int (*fce_loadDepModule)(void *name); +#ifndef __WIN32__ void (*fce_addToExportFce)(char *name, void *function); +#else + void (*fce_addToExportFce)(char *name, HINSTANCE *function); +#endif void* (*fce_getExportFce)(char *name); void (*fce_getTuxProportion)(tux_t *tux, int *x,int *y, int *w, int *h); @@ -56,7 +60,11 @@ typedef struct export_fce_s typedef struct module_s { char *name; +#ifndef __WIN32__ void *image; +#else + HINSTANCE *image; +#endif int (*fce_init)(export_fce_t *p); #ifndef PUBLIC_SERVER -- cgit v1.2.3