|
|
|
@ -198,20 +198,21 @@ void *COM_FunctionFromName( void *hInstance, const char *pName )
@@ -198,20 +198,21 @@ void *COM_FunctionFromName( void *hInstance, const char *pName )
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
#ifdef XASH_DYNAMIC_DLADDR |
|
|
|
|
int d_dladdr( void *sym, Dl_info *info ) |
|
|
|
|
static int d_dladdr( void *sym, Dl_info *info ) |
|
|
|
|
{ |
|
|
|
|
static int (*dladdr_real) ( void *sym, Dl_info *info ); |
|
|
|
|
|
|
|
|
|
if( !dladdr_real ) |
|
|
|
|
dladdr_real = dlsym( (void*)(size_t)(-1), "dladdr" ); |
|
|
|
|
|
|
|
|
|
Q_memset( info, 0, sizeof( *info ) ); |
|
|
|
|
memset( info, 0, sizeof( *info ) ); |
|
|
|
|
|
|
|
|
|
if( !dladdr_real ) |
|
|
|
|
return -1; |
|
|
|
|
|
|
|
|
|
return dladdr_real( sym, info ); |
|
|
|
|
} |
|
|
|
|
#define dladdr d_dladdr |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
const char *COM_NameForFunction( void *hInstance, void *function ) |
|
|
|
|