diff options
author | goodale <goodale@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 1999-11-24 20:50:59 +0000 |
---|---|---|
committer | goodale <goodale@17b73243-c579-4c4c-a9d2-2d5706c11dac> | 1999-11-24 20:50:59 +0000 |
commit | d475e8040a76eb7776eb5ed8f3f3edc0f417f6c7 (patch) | |
tree | e377c6a035918a2ef81c2655946a11b27513e253 /src/main/RecordImplementation.c | |
parent | 1de5cce82d9fac333fba971bd5c19547c4d22abe (diff) |
Removed tabs from files.
Added @version lines to various header files.
Tom
git-svn-id: http://svn.cactuscode.org/flesh/trunk@1170 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'src/main/RecordImplementation.c')
-rw-r--r-- | src/main/RecordImplementation.c | 38 |
1 files changed, 20 insertions, 18 deletions
diff --git a/src/main/RecordImplementation.c b/src/main/RecordImplementation.c index 1acf1d3a..b5bdf9f1 100644 --- a/src/main/RecordImplementation.c +++ b/src/main/RecordImplementation.c @@ -13,6 +13,8 @@ #include "StoreNamedData.h" +static char *rcsid = "$Header$"; + typedef struct { int n_thorns; @@ -37,7 +39,7 @@ static pNamedData *implementation_data = NULL; @@*/ int CCTK_RecordImplementation(const char *implementation, - const char *thorn) + const char *thorn) { int retval; char **temp; @@ -54,12 +56,12 @@ int CCTK_RecordImplementation(const char *implementation, data->thornlist[data->n_thorns-1] = (char *)malloc((strlen(thorn)+1)*sizeof(char)); if(data->thornlist[data->n_thorns-1]) { - strcpy(data->thornlist[data->n_thorns-1], thorn); - retval = 0; + strcpy(data->thornlist[data->n_thorns-1], thorn); + retval = 0; } else { - retval = 4; + retval = 4; } } else @@ -77,23 +79,23 @@ int CCTK_RecordImplementation(const char *implementation, data->thornlist = (char **)malloc(sizeof(char *)); if(data->thornlist) { - data->thornlist[0] = (char *)malloc((strlen(thorn)+1)*sizeof(char)); - if(data->thornlist[0]) - { - strcpy(data->thornlist[0], thorn); - data->n_thorns = 1; - StoreNamedData(&implementation_data,implementation, data); - retval = 0; - } - else - { - retval = 4; - } + data->thornlist[0] = (char *)malloc((strlen(thorn)+1)*sizeof(char)); + if(data->thornlist[0]) + { + strcpy(data->thornlist[0], thorn); + data->n_thorns = 1; + StoreNamedData(&implementation_data,implementation, data); + retval = 0; + } + else + { + retval = 4; + } } else { - fprintf(stderr, "Unable to allocate memory for new thorn %s\n", thorn); - retval = 3; + fprintf(stderr, "Unable to allocate memory for new thorn %s\n", thorn); + retval = 3; } } else |