diff options
| author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2017-05-04 14:19:52 (GMT) |
|---|---|---|
| committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2017-05-04 14:19:52 (GMT) |
| commit | b5273bc1fa5f55149f34824435b65ea807794abc (patch) | |
| tree | 5df08d95415ee2546150f3fcfe45ce1ddcb4e499 /unix/tclUnixTime.c | |
| parent | cdba31b9d5e939cc2f78069f835b086c5aa85a70 (diff) | |
| parent | ce501f14c53a6a094e48453148d08a3e82cfde9a (diff) | |
| download | tcl-b5273bc1fa5f55149f34824435b65ea807794abc.zip tcl-b5273bc1fa5f55149f34824435b65ea807794abc.tar.gz tcl-b5273bc1fa5f55149f34824435b65ea807794abc.tar.bz2 | |
merge trunk
Diffstat (limited to 'unix/tclUnixTime.c')
| -rw-r--r-- | unix/tclUnixTime.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/unix/tclUnixTime.c b/unix/tclUnixTime.c index 315bcf9..6a73ac2 100644 --- a/unix/tclUnixTime.c +++ b/unix/tclUnixTime.c @@ -22,8 +22,9 @@ * variable is the key to this buffer. */ +#ifndef TCL_NO_DEPRECATED static Tcl_ThreadDataKey tmKey; -typedef struct ThreadSpecificData { +typedef struct { struct tm gmtime_buf; struct tm localtime_buf; } ThreadSpecificData; @@ -45,6 +46,8 @@ static char *lastTZ = NULL; /* Holds the last setting of the TZ static void SetTZIfNecessary(void); static void CleanupMemory(ClientData clientData); +#endif /* TCL_NO_DEPRECATED */ + static void NativeScaleTime(Tcl_Time *timebuf, ClientData clientData); static void NativeGetTime(Tcl_Time *timebuf, @@ -158,7 +161,7 @@ TclpGetWideClicks(void) Tcl_Time time; tclGetTimeProcPtr(&time, tclTimeClientData); - now = (Tcl_WideInt) (time.sec*1000000 + time.usec); + now = ((Tcl_WideInt)time.sec)*1000000 + time.usec; } else { #ifdef MAC_OSX_TCL now = (Tcl_WideInt) (mach_absolute_time() & INT64_MAX); @@ -263,6 +266,7 @@ Tcl_GetTime( *---------------------------------------------------------------------- */ +#ifndef TCL_NO_DEPRECATED struct tm * TclpGetDate( const time_t *time, @@ -352,6 +356,7 @@ TclpLocaltime( return &tsdPtr->localtime_buf; } +#endif /* TCL_NO_DEPRECATED */ /* *---------------------------------------------------------------------- @@ -486,6 +491,7 @@ NativeGetTime( *---------------------------------------------------------------------- */ +#ifndef TCL_NO_DEPRECATED static void SetTZIfNecessary(void) { @@ -531,6 +537,7 @@ CleanupMemory( { ckfree(lastTZ); } +#endif /* TCL_NO_DEPRECATED */ /* * Local Variables: |
