X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fruntime%2Fdarwin-dlshim.c;h=05bd340d22072c8ac1e70ae47c8fd672467b7f93;hb=a2b7a6a58e894c02cff583d2d7d1b971a53d7c2d;hp=5f494590493ed7bfe8f8ec5098b0d6933fae7912;hpb=28ed41eb0eed3f0c1baeebf10793a3d21cb0eb9d;p=sbcl.git diff --git a/src/runtime/darwin-dlshim.c b/src/runtime/darwin-dlshim.c index 5f49459..05bd340 100644 --- a/src/runtime/darwin-dlshim.c +++ b/src/runtime/darwin-dlshim.c @@ -32,7 +32,7 @@ static char dl_self; /* I'm going to abuse this */ static int callback_count; -static struct mach_header* last_header; +static const struct mach_header* last_header; #define DLSYM_ERROR 1 #define DLOPEN_ERROR 2 @@ -40,7 +40,7 @@ static struct mach_header* last_header; static int last_error = 0; void -dlshim_image_callback(struct mach_header* ptr, unsigned long phooey) +dlshim_image_callback(const struct mach_header* ptr, intptr_t phooey) { callback_count++; last_header = ptr; @@ -159,7 +159,7 @@ dlopen(const char* filename, int flags) NSLOOKUPSYMBOLINIMAGE_OPTION_RETURN_ON_ERROR); } if (NSIsSymbolNameDefinedInImage(img, "__init")) { - NSSymbol* initsymbol; + NSSymbol initsymbol; void (*initfunc) (void); initsymbol = NSLookupSymbolInImage(img, "__init", 0); initfunc = NSAddressOfSymbol(initsymbol); @@ -204,7 +204,7 @@ dlsym(void* handle, char* symbol) { if (handle == &dl_self) { if (NSIsSymbolNameDefined(symbol)) { - NSSymbol* retsym; + NSSymbol retsym; retsym = NSLookupAndBindSymbol(symbol); return NSAddressOfSymbol(retsym); } else { @@ -213,7 +213,7 @@ dlsym(void* handle, char* symbol) } } else { if (NSIsSymbolNameDefinedInImage(handle, symbol)) { - NSSymbol* retsym; + NSSymbol retsym; retsym = NSLookupSymbolInImage(handle, symbol, 0); return NSAddressOfSymbol(retsym); } else {