summaryrefslogtreecommitdiffstats
path: root/generic/tclClock.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix compiler warnings (discovered on latest clang/gcc6), suggested by Gustaf ↵jan.nijtmans2016-01-211-4/+6
| | | | Neumann. All harmless, no change of functionality.
* Fix [c9eb6b0ac01bb8ef96a616c71426a3db4a279bec|c9eb6b0ac0]: ↵jan.nijtmans2015-12-111-4/+5
| | | | ConvertLocalToUTCUsingC fails the first time if TZ is not set
* Segmentation fault using some functions of tcl::clock, fixed, belong to ↵sebres2014-04-161-18/+21
| | | | ticket [d19a30db57]
* Now that we're no longer using SCM based on RCS, the RCS Keyword lines causedgp2011-03-021-2/+0
|\ | | | | more harm than good. Purged them.
| * Now that we're no longer using SCM based on RCS, the RCS Keyword lines causedgp2011-03-011-2/+0
| | | | | | more harm than good. Purged them.
| * * generic/tclClock.c (FormatClock): Claimed additional space forKevin B Kenny2007-08-251-1/+4
| | | | | | | | | | | | the %c format code to avoid a buffer overrun when formatting (for example) a Friday in February in the Portuguese locale. [Bug 1751117]
| * Restored Cygwin buildability [Bug 1387154]Kevin B Kenny2007-04-211-3/+3
| |
| * replaced 'long' times with wides, to cope with Win64Kevin B Kenny2005-03-151-13/+13
| |
| * 2004-05-14 Kevin B. Kenny <kennykb@acm.org> Kevin B Kenny2004-05-141-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * generic/tclInt.decls: Promoted TclpLocaltime and TclpGmtime * generic/tclIntDecls.h: from Unix-specific stubs to the generic * generic/tclIntPlatDecls.h: internal Stubs table. Reran 'genstubs' * generic/tclStubInit.c: * unix/tclUnixPort.h: * generic/tclClock.c: Changed a buggy 'GMT' timezone specification to the correct 'GMT0'. [Bug #922848] * unix/tclUnixThrd.c: Moved TclpGmtime and TclpLocaltime to unix/tclUnixTime.c where they belong. * unix/tclUnixTime.c (TclpGmtime, TclpLocaltime, TclpGetTimeZone, ThreadSafeGMTime [removed], ThreadSafeLocalTime [removed], SetTZIfNecessary, CleanupMemory): Restructured to make sure that the same mutex protects all calls to localtime, gmtime, and tzset. Added a check in front of those calls to make sure that the TZ env var hasn't changed since the last call to tzset, and repeat tzset if necessary. [Bug #942078] Removed a buggy test of the Daylight Saving Time information in 'gettimeofday' in favor of applying 'localtime' to a known value. [Bug #922848] * tests/clock.test (clock-3.14): Added test to make sure that changes to $env(TZ) take effect immediately. * win/tclWinTime.c (TclpLocaltime, TclpGmtime): Added porting layer for 'localtime' and 'gmtime' calls.
* | * generic/tclInt.decls: Backport of Kevin B. Kenny's work onandreas_kupries2010-11-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * generic/tclInt.h: the Tcl Head, with help from Jeff Hobbs. * generic/tclStrToD.c: * generic/tclTest.c: * generic/tclTomMath.decls: * generic/tclUtil.c: * tests/util.test: * unix/Makefile.in: * win/Makefile.in: * win/makefile.vc: Rewrite of Tcl_PrintDouble and TclDoubleDigits that (a) fixes a severe performance problem with floating point shimmering reported by Karl Lehenbauer, (b) allows TclDoubleDigits to generate the digit strings for 'e' and 'f' format, so that it can be used for tcl_precision != 0 (and possibly later for [format]), (c) fixes [Bug 3120139] by making TclPrintDouble inherently locale-independent, (d) adds test cases to util.test for correct rounding in difficult cases of TclDoubleDigits where fixed- precision results are requested. (e) adds test cases to util.test for the controversial aspects of [Bug 3105247]. As a side effect, two more modules from libtommath (bn_mp_set_int.c and bn_mp_init_set_int.c) are brought into the build, since the new code uses them. * generic/tclIntDecls.h: * generic/tclStubInit.c: * generic/tclTomMathDecls.h: Regenerated.
* | * generic/tclClock.c (TclClockInit): Do not create [clock] supportdgp2009-11-121-1/+10
| | | | | | | | commands in safe interps.
* | * generic/tclClock.c (ClockConvertlocaltoutcObjCmd): Removed leftandreas_kupries2008-06-171-2/+1
| | | | | | | | over debug output.
* | 2006-06-17 Kevin Kenny <kennykb@acm.org>Kevin B Kenny2008-06-171-7/+15
| | | | | | | | | | | | | | | | | | * generic/tclClock.c (ConvertLocalToUTC): * tests/clock.test (clock-63.1): Fixed a bug where the internal ConvertLocalToUTC command segfaulted if passed a dictionary without the 'localSeconds' key. To the best of my knowledge, the bug was not observable in the [clock] command itself.
* | * doc/clock.n: Corrected minor indentation gaffe in theKevin B Kenny2008-02-271-1/+13
| | | | | | | | | | | | | | | | | | | | | | | | penultimate paragraph. [Bug 1898025] * generic/tclClock.c (ParseClockFormatArgs): Changed to check that the clock value is in the range of a 64-bit integer. [Bug 1862555] * library/clock.tcl (::tcl::clock::format, ::tcl::clock::scan, ::tcl::clock::add, ::tcl::clock::LocalizeFormat): Fixed bugs in caching of localized strings that caused weird results when localized date/time formats were used. [Bug 1902423] * tests/clock.test (clock-61.*, clock-62.1): Regression tests for [Bug 1862555] and [Bug 1902423].
* | fix warningdas2008-02-271-2/+2
| |
* | * generic/tclClock.c (ClockParseformatargsObjCmd):Kevin B Kenny2008-02-061-5/+135
| | | | | | | | | | | | | | | | | | | | * library/clock.tcl (::tcl::clock::format): * tests/clock.test (clock-1.0, clock-1.4): Performance enhancements in [clock format] (moving the analysis of $args into C code, holding on to Tcl_Objs with resolved command names, [lassign] in place of [foreach], avoiding [namespace which] for command resolution).
* | merge stable branch onto HEADdgp2007-12-131-1/+1
| |
* | [Patch 1830038]: Increased usage of macros to detect and take advantage of ↵Miguel Sofer2007-11-111-18/+18
| | | | | | | | objTypes.
* | Whitespace policing, replacing commas in varargs with constant string ↵Kevin B Kenny2007-04-201-2/+2
| | | | | | | | catenation, and fixed an oversight in the fix for NZA time zones.
* | Handle creation of Tcl_Objs from constant strings better (easier to use, moredkf2007-04-101-4/+3
| | | | | | | | efficient). After [Patch 1529526] (afredd)
* | simplification of previous commit, whitespace cleanupdas2006-08-281-13/+8
| |
* | Fixes for [Bug 1547662] and [Bug 1547681]Joe Mistachkin2006-08-281-5/+10
| |
* | * generic/tclClock.c (ClockClicksObjCmd): add support for Darwindas2006-08-211-2/+7
| | | | | | | | | | | | | | | | | | * generic/tclCmdMZ.c (Tcl_TimeObjCmd): nanosecond resolution timer * generic/tclInt.h: to [clock clicks] and [time] * unix/configure.in (Darwin): when TCL_WIDE_CLICKS defined. * unix/tclUnixTime.c (TclpGetWideClicks, TclpWideClicksToNanoseconds): * unix/configure: autoconf-2.59 * unix/tclConfig.h.in: autoheader-2.59
* | D'oh! Fix silly mistakes.dkf2006-08-101-3/+3
| |
* | Various minor object file size efficiency fixes. [Bug 1530474]dkf2006-08-101-104/+109
| |
* | typodas2006-08-021-2/+2
| |
* | Bug 1531530Kevin B Kenny2006-07-311-4/+5
| |
* | Bug 1426279Kevin B Kenny2006-07-311-12/+37
| |
* | Restore formatting goodnessdkf2006-02-011-276/+346
| |
* | Export stubs for libtommath; fix mingw compiler warningsKevin B Kenny2005-12-131-2/+2
| |
* | another puny speedup - no error thrown from ::tcl::clock::getenvKevin B Kenny2005-12-021-7/+4
| |
* | * generic/tclClock.c: fix warning.das2005-12-011-3/+7
| |
* | code rationalization - eliminate some duplication between Tcl and CKevin B Kenny2005-11-301-3/+191
| |
* | fix [clock format -timezone :localtime] for times before the Posix EpochKevin B Kenny2005-11-301-4/+9
| |
* | silenced compiler warning about big constantKevin B Kenny2005-11-301-2/+4
| |
* | fixed bad refcount that corrupted heapKevin B Kenny2005-11-301-1/+2
| |
* | make [clock format] go fasterKevin B Kenny2005-11-291-191/+1211
| |
* | ANSIfy. Also converted some deeply nested code to a less nested form for ↵dkf2005-11-011-148/+151
| | | | | | | | easier reading.
* | * generic/tclClock.c: Removed some dead code.dgp2005-10-191-9/+1
| | | | | | | | | | | | | | | | | | | | | | | | * generic/tclCmdIL.c: * generic/tclCompCmds.c: * generic/tclDictObj.c: * generic/tclExecute.c: * generic/tclLiteral.c: * generic/tclParseExpr.c: * generic/tclScan.c: * generic/tclUtil.c: * generic/tclVar.c:
* | bug 1257830Kevin B Kenny2005-08-121-4/+6
| |
* | Squelch a message about an unused variable.dkf2005-08-091-9/+8
| |
* | Bug 1237907Kevin B Kenny2005-07-151-3/+18
| |
* | replaced WIN32 with __WIN32__ [Bug 1054357] (Gravereaux)Kevin B Kenny2004-10-301-2/+2
| |
* | Allow ensembles to rewrite their subcommands' error messages to be moredkf2004-10-291-57/+51
| | | | | | | | | | | | relevant to users. [Patch 1056864] Also patches to core to take advantage of this Also other general cleaning up of Tcl_WrongNumArgs usage
* | doubled speed of clock formatKevin B Kenny2004-10-211-1/+48
| |
* | many more TIP 173 changesKevin B Kenny2004-09-271-104/+1
| |
* | silence compiler warning in tclClock.cKevin B Kenny2004-09-141-2/+2
| |
* | * generic/tclClock.c (TclMktimeObjCmd): Corrected a bad checkKevin B Kenny2004-09-111-2/+5
| | | | | | | | | | | | | | | | | | for error return from 'mktime'. * generic/tclObj.c (Tcl_GetIntFromObj): Corrected a problem where demoting a wide to an int failed on a big-endian machine. [Bug 1026125]. * tests/clock.test (clock-43.1): Added regression test for error return from 'mktime'.
* | * generic/tclClock.c (TclClockMktimeObjCmd): Fixed a bug whereKevin B Kenny2004-09-081-2/+2
| | | | | | | | | | | | the month was scanned incorrectly in -timezone :localtime. * tests/clock.test (clock-40.1): Added regression test case for the bug where month was scanned incorrectly in -timezone :localtime.
* | silence compiler warning on systems without mktimeKevin B Kenny2004-08-181-6/+6
| |