summaryrefslogtreecommitdiff
path: root/src/util/CactusTimers.c
diff options
context:
space:
mode:
authortradke <tradke@17b73243-c579-4c4c-a9d2-2d5706c11dac>2003-09-30 16:41:55 +0000
committertradke <tradke@17b73243-c579-4c4c-a9d2-2d5706c11dac>2003-09-30 16:41:55 +0000
commit980c8870d272e7e185cacca1e7ebe565f81b2550 (patch)
tree995a34ea17376901a2b9e44e386d828aa826fbb5 /src/util/CactusTimers.c
parent2fa6a626e73a29507913d4db5658b5ee68814915 (diff)
Properly initialize an allocated cTimerData structure.
git-svn-id: http://svn.cactuscode.org/flesh/trunk@3416 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'src/util/CactusTimers.c')
-rw-r--r--src/util/CactusTimers.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/util/CactusTimers.c b/src/util/CactusTimers.c
index ff63736f..d3ee2e16 100644
--- a/src/util/CactusTimers.c
+++ b/src/util/CactusTimers.c
@@ -318,7 +318,7 @@ const char *CCTK_TimerName (int timer_handle)
@calls CCTKi_TimerCreate
@var timer name
- @vdesc name for the timer
+ @vdesc name for the timer
@vtype const char *
@vio in
@endvar
@@ -389,7 +389,7 @@ void CCTK_FCALL CCTK_FNAME (CCTK_TimerCreateI)
@enddesc
@var timername
- @vdesc name of the timer
+ @vdesc name of the timer
@vtype const char *
@vio in
@endvar
@@ -600,7 +600,7 @@ static void CCTKi_TimerDestroy (int this_timer, t_Timer *timer)
@calls CCTKi_TimerStart
@var timer name
- @vdesc name for the timer
+ @vdesc name for the timer
@vtype const char *
@vio in
@endvar
@@ -649,7 +649,7 @@ void CCTK_FCALL CCTK_FNAME (CCTK_TimerStart)
@calls CCTKi_TimerStart
@var this_timer
- @vdesc handle for the timer
+ @vdesc handle for the timer
@vtype int
@vio in
@endvar
@@ -1130,12 +1130,12 @@ cTimerData *CCTK_TimerCreateData (void)
cTimerData *retval;
- retval = (cTimerData *) malloc (sizeof (cTimerData));
+ retval = malloc (sizeof (cTimerData));
if (retval)
{
retval->n_vals = n_clock_vals;
- retval->vals = (cTimerVal *) malloc (n_clock_vals * sizeof (cTimerVal));
+ retval->vals = calloc (n_clock_vals, sizeof (cTimerVal));
if (! retval->vals)
{
free (retval);