From 19873b18b08c97be8bf370398f6dff2b3472f52f Mon Sep 17 00:00:00 2001 From: Adhemerval Zanella Date: Wed, 3 Mar 2021 09:36:18 -0300 Subject: io: Add ftw64 with 64-bit time_t support Similar to fts, ftw routines passes a stat pointer that might differ of size and layout when 64-bit time API is used. Checked on i686-linux-gnu and x86_64-linux-gnu. Reviewed-by: Lukasz Majewski Reviewed-by: Carlos O'Donell Tested-by: Carlos O'Donell --- include/ftw.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'include') diff --git a/include/ftw.h b/include/ftw.h index 4fb654cf22..8fb89c4046 100644 --- a/include/ftw.h +++ b/include/ftw.h @@ -1 +1,19 @@ +#ifndef _FTW_H #include + +#ifndef _ISOMAC +# if __TIMESIZE != 64 +# include + +typedef int (*__ftw64_time64_func_t) (const char *, + const struct __stat64_t64 *, int); +typedef int (*__nftw64_time64_func_t) (const char *, + const struct __stat64_t64 *, int, + struct FTW *); + +extern int __ftw64_time64 (const char *, __ftw64_time64_func_t, int); +extern int __nftw64_time64 (const char *, __nftw64_time64_func_t, int, int); +# endif +#endif + +#endif /* _FTW_H */ -- cgit v1.2.3