From 45fc194765402d081a44d1fb4776b3c4aa6fa1d2 Mon Sep 17 00:00:00 2001 From: tradke Date: Mon, 27 Aug 2001 16:46:48 +0000 Subject: Get rid of the prefix when creating named timers so that the other routines, which take the name as the argument, do work again. git-svn-id: http://svn.cactuscode.org/flesh/trunk@2319 17b73243-c579-4c4c-a9d2-2d5706c11dac --- src/util/CactusTimers.c | 24 ++++++------------------ 1 file changed, 6 insertions(+), 18 deletions(-) (limited to 'src') diff --git a/src/util/CactusTimers.c b/src/util/CactusTimers.c index 9383523e..53e2899b 100644 --- a/src/util/CactusTimers.c +++ b/src/util/CactusTimers.c @@ -149,29 +149,17 @@ const char *CCTK_TimerName (int timer_handle) @routine CCTK_TimerCreate @date Wed Sep 1 10:09:57 1999 @author Tom Goodale - @desc - Creates a new timer - @enddesc - @calls - @calledby - @history - - @endhistory - + @desc + Creates a new timer with a given name + @enddesc + @calls CCTKi_TimerCreate @@*/ -int CCTK_TimerCreate(const char *name) +int CCTK_TimerCreate (const char *name) { int retval; - char *timername; - - - /* the name itself might not be unique - so prepend the timer handle */ - timername = (char *) malloc (strlen (name) + 30); - sprintf (timername, "NAMED TIMER %5d -- %s", n_timers, name); - retval = CCTKi_TimerCreate (timername); - free (timername); + retval = CCTKi_TimerCreate (name); return retval; } -- cgit v1.2.3