libredirect: fix access return type

`access` should return `int` not `int*`. Actually compiler produced
identical assembly with any of those types, so by luck it "just worked".
This commit is contained in:
Demin Dmitriy 2019-11-11 03:10:47 +03:00
parent 6432f92e42
commit b6e37c3146

View file

@ -145,9 +145,9 @@ int stat(const char * path, struct stat * st)
return __stat_real(rewrite(path, buf), st);
}
int * access(const char * path, int mode)
int access(const char * path, int mode)
{
int * (*access_real) (const char *, int mode) = dlsym(RTLD_NEXT, "access");
int (*access_real) (const char *, int mode) = dlsym(RTLD_NEXT, "access");
char buf[PATH_MAX];
return access_real(rewrite(path, buf), mode);
}