diff options
author | rmax <rmax> | 2002-06-26 13:42:23 (GMT) |
---|---|---|
committer | rmax <rmax> | 2002-06-26 13:42:23 (GMT) |
commit | 6d29d83763ad48285d295d6b75eafbf085adf40d (patch) | |
tree | d96c82d6c7f5ec68c1c665c9ae3dd176367bb766 /unix | |
parent | f1e972324325cbee2727c085e1d0cd622d9778af (diff) | |
download | tcl-6d29d83763ad48285d295d6b75eafbf085adf40d.zip tcl-6d29d83763ad48285d295d6b75eafbf085adf40d.tar.gz tcl-6d29d83763ad48285d295d6b75eafbf085adf40d.tar.bz2 |
* unix/tclUnixTime.c: Make [clock format] respect locale settings.
* tests/clock.test: Bug #565880. ***POTENTIAL INCOMPATIBILITY***
Diffstat (limited to 'unix')
-rw-r--r-- | unix/tclUnixTime.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/unix/tclUnixTime.c b/unix/tclUnixTime.c index 5107062..85ba721 100644 --- a/unix/tclUnixTime.c +++ b/unix/tclUnixTime.c @@ -9,11 +9,12 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclUnixTime.c,v 1.13 2002/05/29 00:19:39 hobbs Exp $ + * RCS: @(#) $Id: tclUnixTime.c,v 1.14 2002/06/26 13:42:23 rmax Exp $ */ #include "tclInt.h" #include "tclPort.h" +#include <locale.h> #define TM_YEAR_BASE 1900 #define IsLeapYear(x) ((x % 4 == 0) && (x % 100 != 0 || x % 400 == 0)) @@ -332,6 +333,7 @@ TclpStrftime(s, maxsize, format, t, useGMT) (((t->tm_hour * 60) + t->tm_min)/144)); return(strlen(s)); } + setlocale(LC_TIME, ""); return strftime(s, maxsize, format, t); } |