pike.git / src / dynamic_load.c

version» Context lines:

pike.git/src/dynamic_load.c:1:   #ifndef TESTING   # include "global.h"   # include "interpret.h"   # include "constants.h"   # include "error.h"   # include "module.h"   # include "stralloc.h"   # include "pike_macros.h"   # include "main.h"    - RCSID("$Id: dynamic_load.c,v 1.36 1999/04/25 21:07:16 grubba Exp $"); + RCSID("$Id: dynamic_load.c,v 1.37 2000/02/03 19:09:12 grubba Exp $");      #endif /* !TESTING */      #ifdef HAVE_ERRNO_H   #include <errno.h>   #endif /* HAVE_ERRNO_H */   #ifdef HAVE_STRING_H   #include <string.h>   #endif /* HAVE_STRING_H */   
pike.git/src/dynamic_load.c:53: Inside #if defined(HAVE_SOME_DLOPEN)
     static TCHAR *convert_string(char *str, int len)   {    int e;    TCHAR *ret=(TCHAR *)xalloc((len+1) * sizeof(TCHAR));    for(e=0;e<len;e++) ret[e]=EXTRACT_UCHAR(str+e);    ret[e]=0;    return ret;   }    - static void *dlopen(char *foo, int how) + static void *dlopen(const char *foo, int how)   {    TCHAR *tmp;    HINSTANCE ret;    tmp=convert_string(foo, strlen(foo));    ret=LoadLibrary(tmp);    free((char *)tmp);    return (void *)ret;   }      static char * dlerror(void)
pike.git/src/dynamic_load.c:88: Inside #if defined(HAVE_SOME_DLOPEN)
   FreeLibrary((HMODULE)module);   }      #define dlinit()      #endif /* USE_LOADLIBRARY */         #ifdef USE_DLD   #include <dld.h> - static void *dlopen(char *module_name, int how) + static void *dlopen(const char *module_name, int how)   {    dld_create_reference("pike_module_init");    if(dld_link(module_name))    {    return (void *)strdup(module_name);    }else{    return 0;    }   }   
pike.git/src/dynamic_load.c:141:   #include <dl.h>      #if defined(BIND_VERBOSE)   #define RTLD_NOW BIND_IMMEDIATE | BIND_VERBOSE   #else   #define RTLD_NOW BIND_IMMEDIATE   #endif /* BIND_VERBOSE */      extern int errno;    - static void *dlopen(char *libname, int how) + static void *dlopen(const char *libname, int how)   {    shl_t lib;       lib = shl_load(libname, how, 0L);       return (void *)lib;   }      static char *dlerror(void)   {