X-Git-Url: http://nsz.repo.hu/git/?p=musl;a=blobdiff_plain;f=include%2Fdlfcn.h;h=53871ee033fad18c493e21e472daee3d0697eae7;hp=e98c8ca616a842fa5aa782ea2016681d2bb4cece;hb=453059571c9dc84dd168631eced25ec2d7afd98e;hpb=f419bcb9dcfb6af60fbf1d58d92caf4b3d62a4da diff --git a/include/dlfcn.h b/include/dlfcn.h index e98c8ca6..53871ee0 100644 --- a/include/dlfcn.h +++ b/include/dlfcn.h @@ -5,6 +5,12 @@ extern "C" { #endif +#if __STDC_VERSION__ >= 199901L +#define __restrict restrict +#elif !defined(__GNUC__) +#define __restrict +#endif + #define RTLD_LAZY 1 #define RTLD_NOW 2 #define RTLD_GLOBAL 256 @@ -16,9 +22,9 @@ extern "C" { int dlclose(void *); char *dlerror(void); void *dlopen(const char *, int); -void *dlsym(void *, const char *); +void *dlsym(void *__restrict, const char *__restrict); -#ifdef _GNU_SOURCE +#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE) typedef struct { const char *dli_fname; void *dli_fbase;