about summary refs log tree commit diff
path: root/time/strptime_l.c
diff options
context:
space:
mode:
authorAndreas Schwab <schwab@suse.de>2023-01-26 14:25:05 +0100
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2023-02-07 11:03:27 -0300
commitfb7b95dc47b0d5ecd48339512d091b6b23e7d900 (patch)
treef3b4db1e7b687d1c306ab692ee30e9bef0cc8ccb /time/strptime_l.c
parent9f8513dc64119a424b312db97cef5d87d376defa (diff)
downloadglibc-fb7b95dc47b0d5ecd48339512d091b6b23e7d900.tar.gz
glibc-fb7b95dc47b0d5ecd48339512d091b6b23e7d900.tar.xz
glibc-fb7b95dc47b0d5ecd48339512d091b6b23e7d900.zip
Use 64-bit time_t interfaces in strftime and strptime (bug 30053)
Both functions use time_t only internally, so the ABI is not affected.

(cherry picked from commit 41349f6f67c83e7bafe49f985b56493d2c4c9c77)
Diffstat (limited to 'time/strptime_l.c')
-rw-r--r--time/strptime_l.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/time/strptime_l.c b/time/strptime_l.c
index 80fd705b8d..85c3249fcc 100644
--- a/time/strptime_l.c
+++ b/time/strptime_l.c
@@ -30,8 +30,10 @@
 #ifdef _LIBC
 # define HAVE_LOCALTIME_R 0
 # include "../locale/localeinfo.h"
-#endif
 
+# define time_t __time64_t
+# define __localtime_r(t, tp) __localtime64_r (t, tp)
+#endif
 
 #if ! HAVE_LOCALTIME_R && ! defined localtime_r
 # ifdef _LIBC