summaryrefslogtreecommitdiff
path: root/src/main/CommandLine.c
diff options
context:
space:
mode:
authortradke <tradke@17b73243-c579-4c4c-a9d2-2d5706c11dac>2000-02-02 17:23:36 +0000
committertradke <tradke@17b73243-c579-4c4c-a9d2-2d5706c11dac>2000-02-02 17:23:36 +0000
commit49eb5643763a16702f56634fbe004b8df8b95f4c (patch)
tree2ec282ab49f54b32d694d66c5d4f96b7531ab93b /src/main/CommandLine.c
parentefe1846d2629923afbcf138958d81d0eeb622631 (diff)
Replaced CCTKi_ThornList() by CCTK_NumCompiledThorns() and CCTK_CompiledThorn().
git-svn-id: http://svn.cactuscode.org/flesh/trunk@1336 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'src/main/CommandLine.c')
-rw-r--r--src/main/CommandLine.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/src/main/CommandLine.c b/src/main/CommandLine.c
index 730f23fd..bcdefb8e 100644
--- a/src/main/CommandLine.c
+++ b/src/main/CommandLine.c
@@ -76,24 +76,25 @@ void CCTKi_CommandLineTestThornCompiled(const char *optarg)
void CCTKi_CommandLineDescribeAllParameters(const char *optarg)
{
int n_thorns;
- char **thornlist;
int thorn;
int n_parameters;
char **parameterlist;
int parameter;
+ const char *thornname;
const char *implementation;
t_param_prop *properties;
- CCTKi_ThornList(0, &thornlist, &n_thorns);
+ n_thorns = CCTK_NumCompiledThorns ();
for(thorn = 0; thorn < n_thorns; thorn++)
{
- implementation = CCTK_ThornImplementation(thornlist[thorn]);
- CCTK_ParameterList(thornlist[thorn], &parameterlist, &n_parameters);
+ thornname = CCTK_CompiledThorn (thorn);
+ implementation = CCTK_ThornImplementation(thornname);
+ CCTK_ParameterList(thornname, &parameterlist, &n_parameters);
for(parameter = 0 ; parameter < n_parameters; parameter++)
{
- properties = CCTK_ParameterInfo(parameterlist[parameter], thornlist[thorn]);
+ properties = CCTK_ParameterInfo(parameterlist[parameter], thornname);
if(optarg)
{
@@ -111,7 +112,7 @@ void CCTKi_CommandLineDescribeAllParameters(const char *optarg)
{
if(properties->scope == SCOPE_PRIVATE)
{
- printf("%s::%s\n", thornlist[thorn], parameterlist[parameter]);
+ printf("%s::%s\n", thornname, parameterlist[parameter]);
}
else
{
@@ -122,9 +123,7 @@ void CCTKi_CommandLineDescribeAllParameters(const char *optarg)
free(parameterlist[parameter]);
}
free(parameterlist);
- free(thornlist[thorn]);
}
- free(thornlist);
/* CCTKi_BindingsParameterHelp(NULL,"%s",stdout);*/