diff options
author | Adhemerval Zanella <adhemerval.zanella@linaro.org> | 2021-03-02 20:17:07 -0300 |
---|---|---|
committer | Adhemerval Zanella <adhemerval.zanella@linaro.org> | 2021-06-15 10:42:11 -0300 |
commit | 84f7ce84474c1648ce96884f1c91ca7b97ca3fc2 (patch) | |
tree | 4a19687d260d69a380414d41a592fb261841e5cd /posix/glob.h | |
parent | 47f24c21ee38701ae275aa9e451f70fa3e77478c (diff) | |
download | glibc-84f7ce84474c1648ce96884f1c91ca7b97ca3fc2.zip glibc-84f7ce84474c1648ce96884f1c91ca7b97ca3fc2.tar.gz glibc-84f7ce84474c1648ce96884f1c91ca7b97ca3fc2.tar.bz2 |
posix: Add glob64 with 64-bit time_t support
The glob might pass a different stat struct for gl_stat and gl_lstat
when GLOB_ALTDIRFUNC is used. This requires add a new 64-bit time
version that also uses 64-bit time stat functions.
Checked on i686-linux-gnu and x86_64-linux-gnu.
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Tested-by: Carlos O'Donell <carlos@redhat.com>
Diffstat (limited to 'posix/glob.h')
-rw-r--r-- | posix/glob.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/posix/glob.h b/posix/glob.h index b568660..700aeb2 100644 --- a/posix/glob.h +++ b/posix/glob.h @@ -150,20 +150,42 @@ extern int glob (const char *__restrict __pattern, int __flags, /* Free storage allocated in PGLOB by a previous `glob' call. */ extern void globfree (glob_t *__pglob) __THROW; #else +# ifdef __USE_TIME_BITS64 +extern int __REDIRECT_NTHNL (glob, (const char *__restrict __pattern, + int __flags, + int (*__errfunc) (const char *, int), + glob_t *__restrict __pglob), + __glob64_time64); + +extern void __REDIRECT_NTH (globfree, (glob_t *__pglob), + __globfree64_time64); +# else extern int __REDIRECT_NTHNL (glob, (const char *__restrict __pattern, int __flags, int (*__errfunc) (const char *, int), glob_t *__restrict __pglob), glob64); extern void __REDIRECT_NTH (globfree, (glob_t *__pglob), globfree64); +# endif #endif #ifdef __USE_LARGEFILE64 +# ifdef __USE_TIME_BITS64 +extern int __REDIRECT_NTHNL (glob64, (const char *__restrict __pattern, + int __flags, + int (*__errfunc) (const char *, int), + glob64_t *__restrict __pglob), + __glob64_time64); + +extern void __REDIRECT_NTH (globfree64, (glob64_t *__pglob), + __globfree64_time64); +# else extern int glob64 (const char *__restrict __pattern, int __flags, int (*__errfunc) (const char *, int), glob64_t *__restrict __pglob) __THROWNL; extern void globfree64 (glob64_t *__pglob) __THROW; +# endif #endif |