summaryrefslogtreecommitdiffstats
path: root/newlib/libc/time/local.h
diff options
context:
space:
mode:
authorJeff Johnston <jjohnstn@redhat.com>2014-09-11 21:55:01 +0000
committerJeff Johnston <jjohnstn@redhat.com>2014-09-11 21:55:01 +0000
commitc9dded6775ca8a0934739f56c29337a893b5da7c (patch)
treeefa76c7c6c04acf2466794f73d540620c42cce86 /newlib/libc/time/local.h
parent1c5ab1f862dd2f0715a12d4886f4f39d8e4c2b20 (diff)
downloadcygnal-c9dded6775ca8a0934739f56c29337a893b5da7c.tar.gz
cygnal-c9dded6775ca8a0934739f56c29337a893b5da7c.tar.bz2
cygnal-c9dded6775ca8a0934739f56c29337a893b5da7c.zip
2014-09-11 Freddie Chopin <freddie_chopin@op.pl>
* libc/time/month_lengths.c: New file with __month_lengths array (previously mon_lengths array in mktm_r.c) * libc/time/tzcalc_limits.c: New file with __tzcalc_limits() from mktm_r.c * libc/time/lcltime_r.c (localtime_r): Simplify by changing call to _mktm_r() with call to gmtime_r() and code moved from _mktm_r() which was used to do time zone adjustments * libc/time/gmtime_r.c (gmtime_r): Simplify by moving all relevant code from _mktm_r(), breaking all dependencies on time zone related functions * libc/time/mktm_r.c: Delete file * libc/time/local.h: Update accordingly - remove declaration of _mktm_r(), add declaration of __month_lengths[] * libc/time/Makefile.am: Modify accordingly. * libc/time/Makefile.in: Regenerate.
Diffstat (limited to 'newlib/libc/time/local.h')
-rw-r--r--newlib/libc/time/local.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/newlib/libc/time/local.h b/newlib/libc/time/local.h
index 9d9ef87fa..5fc3ddcb1 100644
--- a/newlib/libc/time/local.h
+++ b/newlib/libc/time/local.h
@@ -19,9 +19,10 @@
#define isleap(y) ((((y) % 4) == 0 && ((y) % 100) != 0) || ((y) % 400) == 0)
-struct tm * _EXFUN (_mktm_r, (_CONST time_t *, struct tm *, int __is_gmtime));
int _EXFUN (__tzcalc_limits, (int __year));
+extern _CONST int __month_lengths[2][MONSPERYEAR];
+
/* locks for multi-threading */
#ifdef __SINGLE_THREAD__
#define TZ_LOCK