From 5a64607d5429451e1930b46bfc815b03cac12b25 Mon Sep 17 00:00:00 2001 From: Andreas Baumann Date: Fri, 4 Jun 2010 17:11:16 +0200 Subject: added a const char * mapper for dlerror --- src/library/loader.c | 2 +- src/port/sys_internal.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/library/loader.c b/src/library/loader.c index 0e2c1f7..ca11fe4 100644 --- a/src/library/loader.c +++ b/src/library/loader.c @@ -135,7 +135,7 @@ char *wolf_library_error_msg( const wolf_library_p library, char *buf, size_t b WOLF_LIBRARY_FUNCPTR wolf_library_get_func( const wolf_library_p l, const char *name, wolf_error_t *error ) { WOLF_LIBRARY_FUNCPTR ret; - char *err = NULL; + WOLF_LIBRARY_DLERROR_CONST char *err = NULL; #if defined HAVE_DLFCN /* clear error state before calling dlsym, so that calling dlsym diff --git a/src/port/sys_internal.h b/src/port/sys_internal.h index e7aa27e..d0c2f94 100644 --- a/src/port/sys_internal.h +++ b/src/port/sys_internal.h @@ -74,6 +74,7 @@ #define HAVE_LOCK_F #define HAVE_LOCALTIME_R #define HAVE_DLFCN +#define WOLF_LIBRARY_DLERROR_CONST const #else #error unknown platform #endif /* defined OS_MINOR_VERSION >= 2 && OS_MINOR_VERSION <= 7 */ -- cgit v1.2.3-54-g00ecf