diff options
| author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2021-02-19 15:11:19 (GMT) |
|---|---|---|
| committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2021-02-19 15:11:19 (GMT) |
| commit | 17199973cb85d23394ffe2fbc5087aa18a311ac6 (patch) | |
| tree | e93d9661a9cda87927eafb679acfe44c6d1edbc1 /unix | |
| parent | 3938624851b217aefcd2b7ca17c4de831d3d3bbb (diff) | |
| parent | 8512e037c283c963896ccc29a5118e64a9b5e830 (diff) | |
| download | tcl-17199973cb85d23394ffe2fbc5087aa18a311ac6.zip tcl-17199973cb85d23394ffe2fbc5087aa18a311ac6.tar.gz tcl-17199973cb85d23394ffe2fbc5087aa18a311ac6.tar.bz2 | |
Merge 9.0
Diffstat (limited to 'unix')
| -rw-r--r-- | unix/tclUnixTime.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/unix/tclUnixTime.c b/unix/tclUnixTime.c index dc48a32..990503d 100644 --- a/unix/tclUnixTime.c +++ b/unix/tclUnixTime.c @@ -49,10 +49,10 @@ void *tclTimeClientData = NULL; *---------------------------------------------------------------------- */ -Tcl_WideUInt +unsigned long long TclpGetSeconds(void) { - return time(NULL); + return (unsigned long long)time(NULL); } /* @@ -78,7 +78,7 @@ TclpGetMicroseconds(void) Tcl_Time time; tclGetTimeProcPtr(&time, tclTimeClientData); - return ((long long)time.sec)*1000000 + time.usec; + return ((long long)(unsigned long)time.sec)*1000000 + time.usec; } /* @@ -100,30 +100,30 @@ TclpGetMicroseconds(void) *---------------------------------------------------------------------- */ -Tcl_WideUInt +unsigned long long TclpGetClicks(void) { - Tcl_WideUInt now; + unsigned long long now; #ifdef NO_GETTOD if (tclGetTimeProcPtr != NativeGetTime) { Tcl_Time time; tclGetTimeProcPtr(&time, tclTimeClientData); - now = (Tcl_WideUInt)time.sec*1000000 + time.usec; + now = (unsigned long long)(unsigned long)time.sec*1000000 + time.usec; } else { /* * A semi-NativeGetTime, specialized to clicks. */ struct tms dummy; - now = (Tcl_WideUInt) times(&dummy); + now = (unsigned long long)times(&dummy); } #else Tcl_Time time; tclGetTimeProcPtr(&time, tclTimeClientData); - now = (Tcl_WideUInt)time.sec*1000000 + time.usec; + now = (unsigned long long)time.sec*1000000 + time.usec; #endif return now; |
