X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/2d21ac55c334faf3a56e5634905ed6987fc787d4..593a1d5fd87cdf5b46dd5fcb84467b432cea0f91:/libsyscall/mach/exc_catcher.c diff --git a/libsyscall/mach/exc_catcher.c b/libsyscall/mach/exc_catcher.c index 507cb1000..a85086519 100644 --- a/libsyscall/mach/exc_catcher.c +++ b/libsyscall/mach/exc_catcher.c @@ -35,7 +35,7 @@ #include #include #include -#include +#include #include __private_extern__ kern_return_t internal_catch_exception_raise ( @@ -52,7 +52,7 @@ __private_extern__ kern_return_t internal_catch_exception_raise ( static kern_return_t (*func)(mach_port_t, mach_port_t, mach_port_t, exception_type_t, exception_data_t, mach_msg_type_number_t); if (checkForFunction == 0) { checkForFunction = 1; - _dyld_lookup_and_bind("_catch_exception_raise", (unsigned long *)&func, (void **)0); + func = dlsym(RTLD_DEFAULT, "catch_exception_raise"); } if (func == 0) { /* The user hasn't defined catch_exception_raise in their binary */