summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/include/CommandLine.h12
-rw-r--r--src/main/CommandLine.c48
-rw-r--r--src/main/ProcessCommandLine.c2
-rw-r--r--src/main/ScheduleInterface.c10
-rw-r--r--src/main/SetParams.c2
-rw-r--r--src/main/Stagger.c1
6 files changed, 40 insertions, 35 deletions
diff --git a/src/include/CommandLine.h b/src/include/CommandLine.h
index 0c679a89..e7ee50dc 100644
--- a/src/include/CommandLine.h
+++ b/src/include/CommandLine.h
@@ -14,12 +14,12 @@
extern "C" {
#endif
-void CCTKi_CommandLineTestThornCompiled(const char *optarg);
-void CCTKi_CommandLineDescribeAllParameters(const char *optarg);
-void CCTKi_CommandLineDescribeParameter(const char *optarg);
-void CCTKi_CommandLineTestParameters(const char *optarg);
-void CCTKi_CommandLineWarningLevel(const char *optarg);
-void CCTKi_CommandLineErrorLevel(const char *optarg);
+void CCTKi_CommandLineTestThornCompiled(const char *argument);
+void CCTKi_CommandLineDescribeAllParameters(const char *argument);
+void CCTKi_CommandLineDescribeParameter(const char *argument);
+void CCTKi_CommandLineTestParameters(const char *argument);
+void CCTKi_CommandLineWarningLevel(const char *argument);
+void CCTKi_CommandLineErrorLevel(const char *argument);
void CCTKi_CommandLineRedirectStdout(void);
void CCTKi_CommandLineListThorns(void);
void CCTKi_CommandLineVersion(void);
diff --git a/src/main/CommandLine.c b/src/main/CommandLine.c
index 7a12b0b5..16b1a125 100644
--- a/src/main/CommandLine.c
+++ b/src/main/CommandLine.c
@@ -83,7 +83,7 @@ int cctki_paramcheck_nprocs;
@history
@endhistory
- @var optarg
+ @var argument
@vdesc option argument
@vtype const char *
@vio in
@@ -93,22 +93,22 @@ int cctki_paramcheck_nprocs;
@@*/
-void CCTKi_CommandLineTestThornCompiled(const char *optarg)
+void CCTKi_CommandLineTestThornCompiled(const char *argument)
{
int retval;
- if((retval = CCTK_IsThornCompiled(optarg)))
+ if((retval = CCTK_IsThornCompiled(argument)))
{
if (CCTK_MyProc(NULL) == 0)
{
- printf("Thorn '%s' available.\n", optarg);
+ printf("Thorn '%s' available.\n", argument);
}
}
else
{
if (CCTK_MyProc(NULL) == 0)
{
- printf("Thorn '%s' unavailable.\n", optarg);
+ printf("Thorn '%s' unavailable.\n", argument);
}
}
@@ -128,7 +128,7 @@ void CCTKi_CommandLineTestThornCompiled(const char *optarg)
@history
@endhistory
- @var optarg
+ @var argument
@vdesc option argument
@vtype const char *
@vio in
@@ -137,7 +137,7 @@ void CCTKi_CommandLineTestThornCompiled(const char *optarg)
@endvar
@@*/
-void CCTKi_CommandLineDescribeAllParameters(const char *optarg)
+void CCTKi_CommandLineDescribeAllParameters(const char *argument)
{
int first;
int n_thorns;
@@ -159,15 +159,15 @@ void CCTKi_CommandLineDescribeAllParameters(const char *optarg)
first = 1;
while (CCTK_ParameterWalk (first, thornname, &param, &properties) == 0)
{
- if(optarg)
+ if(argument)
{
- switch(*optarg)
+ switch(*argument)
{
case 'v':
CommandLinePrintParameter(properties);
break;
default :
- fprintf(stderr, "Unknown verbosity option %s\n", optarg);
+ fprintf(stderr, "Unknown verbosity option %s\n", argument);
CCTK_Exit(NULL,2);
}
}
@@ -197,7 +197,7 @@ void CCTKi_CommandLineDescribeAllParameters(const char *optarg)
@history
@endhistory
- @var optarg
+ @var argument
@vdesc option argument
@vtype const char *
@vio in
@@ -206,7 +206,7 @@ void CCTKi_CommandLineDescribeAllParameters(const char *optarg)
@endvar
@@*/
-void CCTKi_CommandLineDescribeParameter(const char *optarg)
+void CCTKi_CommandLineDescribeParameter(const char *argument)
{
char *thorn;
char *param;
@@ -215,11 +215,11 @@ void CCTKi_CommandLineDescribeParameter(const char *optarg)
if (CCTK_MyProc(NULL) == 0)
{
- Util_SplitString(&thorn, &param, optarg, "::");
+ Util_SplitString(&thorn, &param, argument, "::");
if(!param)
{
- properties = CCTK_ParameterData(optarg, NULL);
+ properties = CCTK_ParameterData(argument, NULL);
}
else
{
@@ -253,7 +253,7 @@ void CCTKi_CommandLineDescribeParameter(const char *optarg)
@history
@endhistory
- @var optarg
+ @var argument
@vdesc option argument
@vtype const char *
@vio in
@@ -262,17 +262,17 @@ void CCTKi_CommandLineDescribeParameter(const char *optarg)
@endvar
@@*/
-void CCTKi_CommandLineTestParameters(const char *optarg)
+void CCTKi_CommandLineTestParameters(const char *argument)
{
int nprocs;
- if(optarg == NULL)
+ if(argument == NULL)
{
nprocs = 1;
}
else
{
- nprocs = atoi(optarg);
+ nprocs = atoi(argument);
}
paramchecking = 1;
@@ -293,7 +293,7 @@ void CCTKi_CommandLineTestParameters(const char *optarg)
@history
@endhistory
- @var optarg
+ @var argument
@vdesc option argument
@vtype const char *
@vio in
@@ -303,11 +303,11 @@ void CCTKi_CommandLineTestParameters(const char *optarg)
@@*/
-void CCTKi_CommandLineWarningLevel(const char *optarg)
+void CCTKi_CommandLineWarningLevel(const char *argument)
{
int warninglevel;
- warninglevel = atoi(optarg);
+ warninglevel = atoi(argument);
CCTKi_SetWarnLevel(warninglevel);
@@ -325,7 +325,7 @@ void CCTKi_CommandLineWarningLevel(const char *optarg)
@history
@endhistory
- @var optarg
+ @var argument
@vdesc option argument
@vtype const char *
@vio in
@@ -334,11 +334,11 @@ void CCTKi_CommandLineWarningLevel(const char *optarg)
@endvar
@@*/
-void CCTKi_CommandLineErrorLevel(const char *optarg)
+void CCTKi_CommandLineErrorLevel(const char *argument)
{
int errorlevel;
- errorlevel = atoi(optarg);
+ errorlevel = atoi(argument);
CCTKi_SetErrorLevel(errorlevel);
diff --git a/src/main/ProcessCommandLine.c b/src/main/ProcessCommandLine.c
index 61e22863..a4fa9929 100644
--- a/src/main/ProcessCommandLine.c
+++ b/src/main/ProcessCommandLine.c
@@ -9,9 +9,11 @@
@@*/
#include <stdio.h>
#include <stdlib.h>
+#include <string.h>
#include "cctk_Flesh.h"
#include "cctk_GNU.h"
+#include "cctk_Misc.h"
#include "CommandLine.h"
diff --git a/src/main/ScheduleInterface.c b/src/main/ScheduleInterface.c
index bac860e5..1126ac6d 100644
--- a/src/main/ScheduleInterface.c
+++ b/src/main/ScheduleInterface.c
@@ -2102,7 +2102,7 @@ static int CCTKi_ScheduleCallEntry(t_attribute *attribute,
t_sched_data *data)
{
int i;
- int index;
+ int indx;
int last;
int go;
@@ -2115,11 +2115,11 @@ static int CCTKi_ScheduleCallEntry(t_attribute *attribute,
/* In analysis, so check triggers */
for (i = 0; i < attribute->n_trigger_groups ; i++)
{
- index = CCTK_FirstVarIndexI(attribute->trigger_groups[i]);
- last = index + CCTK_NumVarsInGroupI(attribute->trigger_groups[i]) -1;
- for(; index <= last ; index++)
+ indx = CCTK_FirstVarIndexI(attribute->trigger_groups[i]);
+ last = indx + CCTK_NumVarsInGroupI(attribute->trigger_groups[i]) -1;
+ for(; indx <= last ; indx++)
{
- go = go || CCTKi_TriggerSaysGo(data->GH, index);
+ go = go || CCTKi_TriggerSaysGo(data->GH, indx);
}
}
}
diff --git a/src/main/SetParams.c b/src/main/SetParams.c
index 03fc7e9d..461f6471 100644
--- a/src/main/SetParams.c
+++ b/src/main/SetParams.c
@@ -22,6 +22,8 @@
#include "cctk_Flesh.h"
#include "cctk_Parameter.h"
+#include "cctki_Parameter.h"
+
#include "ParameterBindings.h"
static char *rcsid = "$Header$";
diff --git a/src/main/Stagger.c b/src/main/Stagger.c
index b6f1b0df..ae930675 100644
--- a/src/main/Stagger.c
+++ b/src/main/Stagger.c
@@ -19,6 +19,7 @@
#include "cctk_Types.h"
#include "cctk_WarnLevel.h"
+#include "cctk_Stagger.h"
#include "cctki_Stagger.h"
static char *rcsid = "$Header$";