diff options
author | Andrey A. Chernov <ache@FreeBSD.org> | 1999-11-30 07:33:37 +0000 |
---|---|---|
committer | Andrey A. Chernov <ache@FreeBSD.org> | 1999-11-30 07:33:37 +0000 |
commit | 11cd0d324175da41324f7f35ac3e08146bb8577f (patch) | |
tree | 650dd2254c98b3efaaf334274c5d6b9c4ef4bf85 /lib/libc/stdtime/timelocal.c | |
parent | 8e0788736e57869c19be722c72ed7ad9de39b14d (diff) |
Notes
Diffstat (limited to 'lib/libc/stdtime/timelocal.c')
-rw-r--r-- | lib/libc/stdtime/timelocal.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/lib/libc/stdtime/timelocal.c b/lib/libc/stdtime/timelocal.c index f58488a3bf9b..369feb7ccd97 100644 --- a/lib/libc/stdtime/timelocal.c +++ b/lib/libc/stdtime/timelocal.c @@ -46,6 +46,8 @@ int _time_using_locale; #define LCTIME_SIZE_FULL (sizeof(struct lc_time_T) / sizeof(char *)) #define LCTIME_SIZE_1 \ (offsetof(struct lc_time_T, alt_month[0]) / sizeof(char *)) +#define LCTIME_SIZE_2 \ + (offsetof(struct lc_time_T, Ex_fmt) / sizeof(char *)) const struct lc_time_T _C_time_locale = { { @@ -80,7 +82,7 @@ const struct lc_time_T _C_time_locale = { ** "%a %b %d %H:%M:%S %Y" ** is used by Solaris 2.3. */ - "%a %b %e %X %Y", + "%a %Ex %X %Y", /* am */ "AM", @@ -89,12 +91,17 @@ const struct lc_time_T _C_time_locale = { "PM", /* date_fmt */ - "%a %b %e %X %Z %Y", + "%a %Ex %X %Z %Y", { "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" - } + }, + + /* Ex_fmt + ** To determine months / day order + */ + "%b %e" }; @@ -173,6 +180,8 @@ __time_load_locale(const char *name) num_lines = split_lines(p, plim); if (num_lines >= LCTIME_SIZE_FULL) num_lines = LCTIME_SIZE_FULL; + else if (num_lines >= LCTIME_SIZE_2) + num_lines = LCTIME_SIZE_2; else if (num_lines >= LCTIME_SIZE_1) num_lines = LCTIME_SIZE_1; else |