summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixTime.c
diff options
context:
space:
mode:
Diffstat (limited to 'unix/tclUnixTime.c')
-rw-r--r--unix/tclUnixTime.c38
1 files changed, 19 insertions, 19 deletions
diff --git a/unix/tclUnixTime.c b/unix/tclUnixTime.c
index b98f2e1..02a90a5 100644
--- a/unix/tclUnixTime.c
+++ b/unix/tclUnixTime.c
@@ -112,7 +112,7 @@ TclpGetClicks(void)
if (tclGetTimeProcPtr != NativeGetTime) {
Tcl_Time time;
- (*tclGetTimeProcPtr) (&time, tclTimeClientData);
+ tclGetTimeProcPtr(&time, tclTimeClientData);
now = time.sec*1000000 + time.usec;
} else {
/*
@@ -125,7 +125,7 @@ TclpGetClicks(void)
#else
Tcl_Time time;
- (*tclGetTimeProcPtr) (&time, tclTimeClientData);
+ tclGetTimeProcPtr(&time, tclTimeClientData);
now = time.sec*1000000 + time.usec;
#endif
@@ -134,7 +134,7 @@ TclpGetClicks(void)
#ifdef TCL_WIDE_CLICKS
/*
- *-----------------------------------------------------------------------------
+ *----------------------------------------------------------------------
*
* TclpGetWideClicks --
*
@@ -149,7 +149,7 @@ TclpGetClicks(void)
* Side effects:
* None.
*
- *-----------------------------------------------------------------------------
+ *----------------------------------------------------------------------
*/
Tcl_WideInt
@@ -160,7 +160,7 @@ TclpGetWideClicks(void)
if (tclGetTimeProcPtr != NativeGetTime) {
Tcl_Time time;
- (*tclGetTimeProcPtr) (&time, tclTimeClientData);
+ tclGetTimeProcPtr(&time, tclTimeClientData);
now = (Tcl_WideInt) (time.sec*1000000 + time.usec);
} else {
#ifdef MAC_OSX_TCL
@@ -174,7 +174,7 @@ TclpGetWideClicks(void)
}
/*
- *-----------------------------------------------------------------------------
+ *----------------------------------------------------------------------
*
* TclpWideClicksToNanoseconds --
*
@@ -187,7 +187,7 @@ TclpGetWideClicks(void)
* Side effects:
* None.
*
- *-----------------------------------------------------------------------------
+ *----------------------------------------------------------------------
*/
double
@@ -361,7 +361,7 @@ void
Tcl_GetTime(
Tcl_Time *timePtr) /* Location to store time information. */
{
- (*tclGetTimeProcPtr) (timePtr, tclTimeClientData);
+ tclGetTimeProcPtr(timePtr, tclTimeClientData);
}
/*
@@ -384,7 +384,7 @@ Tcl_GetTime(
struct tm *
TclpGetDate(
- CONST time_t *time,
+ const time_t *time,
int useGMT)
{
if (useGMT) {
@@ -412,7 +412,7 @@ TclpGetDate(
struct tm *
TclpGmtime(
- CONST time_t *timePtr) /* Pointer to the number of seconds since the
+ const time_t *timePtr) /* Pointer to the number of seconds since the
* local system's epoch */
{
/*
@@ -422,14 +422,14 @@ TclpGmtime(
ThreadSpecificData *tsdPtr = TCL_TSD_INIT(&tmKey);
#ifdef HAVE_GMTIME_R
- gmtime_r(timePtr, &(tsdPtr->gmtime_buf));
+ gmtime_r(timePtr, &tsdPtr->gmtime_buf);
#else
Tcl_MutexLock(&tmMutex);
- memcpy(&(tsdPtr->gmtime_buf), gmtime(timePtr), sizeof(struct tm));
+ memcpy(&tsdPtr->gmtime_buf, gmtime(timePtr), sizeof(struct tm));
Tcl_MutexUnlock(&tmMutex);
#endif
- return &(tsdPtr->gmtime_buf);
+ return &tsdPtr->gmtime_buf;
}
/*
@@ -451,7 +451,7 @@ TclpGmtime(
struct tm *
TclpLocaltime(
- CONST time_t *timePtr) /* Pointer to the number of seconds since the
+ const time_t *timePtr) /* Pointer to the number of seconds since the
* local system's epoch */
{
/*
@@ -462,14 +462,14 @@ TclpLocaltime(
SetTZIfNecessary();
#ifdef HAVE_LOCALTIME_R
- localtime_r(timePtr, &(tsdPtr->localtime_buf));
+ localtime_r(timePtr, &tsdPtr->localtime_buf);
#else
Tcl_MutexLock(&tmMutex);
- memcpy(&(tsdPtr->localtime_buf), localtime(timePtr), sizeof(struct tm));
+ memcpy(&tsdPtr->localtime_buf, localtime(timePtr), sizeof(struct tm));
Tcl_MutexUnlock(&tmMutex);
#endif
- return &(tsdPtr->localtime_buf);
+ return &tsdPtr->localtime_buf;
}
/*
@@ -608,7 +608,7 @@ NativeGetTime(
static void
SetTZIfNecessary(void)
{
- CONST char *newTZ = getenv("TZ");
+ const char *newTZ = getenv("TZ");
Tcl_MutexLock(&tmMutex);
if (newTZ == NULL) {
@@ -617,7 +617,7 @@ SetTZIfNecessary(void)
if (lastTZ == NULL || strcmp(lastTZ, newTZ)) {
tzset();
if (lastTZ == NULL) {
- Tcl_CreateExitHandler(CleanupMemory, (ClientData) NULL);
+ Tcl_CreateExitHandler(CleanupMemory, NULL);
} else {
Tcl_Free(lastTZ);
}