Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mpim-sw
libcdi
Commits
80aa8556
Commit
80aa8556
authored
Jun 30, 2017
by
Uwe Schulzweida
Browse files
Removed unused function tableInqPar().
parent
55cde1d5
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/cdi.h
View file @
80aa8556
...
...
@@ -1216,7 +1216,6 @@ int tableRead(const char *tablefile);
int
tableDef
(
int
modelID
,
int
tablenum
,
const
char
*
tablename
);
const
char
*
tableInqNamePtr
(
int
tableID
);
void
tableDefEntry
(
int
tableID
,
int
code
,
const
char
*
name
,
const
char
*
longname
,
const
char
*
units
);
int
tableInq
(
int
modelID
,
int
tablenum
,
const
char
*
tablename
);
int
tableInqNumber
(
void
);
...
...
@@ -1224,8 +1223,6 @@ int tableInqNumber(void);
int
tableInqNum
(
int
tableID
);
int
tableInqModel
(
int
tableID
);
void
tableInqPar
(
int
tableID
,
int
code
,
char
*
name
,
char
*
longname
,
char
*
units
);
int
tableInqParCode
(
int
tableID
,
char
*
name
,
int
*
code
);
int
tableInqParName
(
int
tableID
,
int
code
,
char
*
name
);
int
tableInqParLongname
(
int
tableID
,
int
code
,
char
*
longname
);
...
...
src/table.c
View file @
80aa8556
...
...
@@ -41,8 +41,8 @@ static char *tablePath = NULL;
static
void
tableDefModelID
(
int
tableID
,
int
modelID
);
static
void
tableDefNum
(
int
tableID
,
int
tablenum
);
void
tableDefEntry
(
int
tableID
,
int
id
,
const
char
*
name
,
static
void
tableDefEntry
(
int
tableID
,
int
id
,
int
ltype
,
const
char
*
name
,
const
char
*
longname
,
const
char
*
units
)
{
if
(
tableID
>=
0
&&
tableID
<
MAX_TABLE
&&
parTable
[
tableID
].
used
)
{
}
else
...
...
@@ -50,6 +50,7 @@ void tableDefEntry(int tableID, int id, const char *name,
int
item
=
parTable
[
tableID
].
npars
++
;
parTable
[
tableID
].
pars
[
item
].
id
=
id
;
parTable
[
tableID
].
pars
[
item
].
ltype
=
ltype
;
parTable
[
tableID
].
pars
[
item
].
dupflags
=
0
;
parTable
[
tableID
].
pars
[
item
].
name
=
NULL
;
parTable
[
tableID
].
pars
[
item
].
longname
=
NULL
;
...
...
@@ -378,7 +379,7 @@ int tableRead(const char *tablefile)
if
(
name
[
0
]
==
0
)
sprintf
(
name
,
"var%d"
,
id
);
tableDefEntry
(
tableID
,
id
,
name
,
longname
,
units
);
tableDefEntry
(
tableID
,
id
,
ltype
,
name
,
longname
,
units
);
}
return
tableID
;
...
...
@@ -941,28 +942,6 @@ int tableInqParUnits(int tableID, int code, char *units)
}
void
tableInqPar
(
int
tableID
,
int
code
,
char
*
name
,
char
*
longname
,
char
*
units
)
{
if
(
((
tableID
>=
0
)
&
(
tableID
<
MAX_TABLE
))
|
(
tableID
==
CDI_UNDEFID
)
)
{
}
else
Error
(
"Invalid table ID %d"
,
tableID
);
int
npars
=
parTable
[
tableID
].
npars
;
for
(
int
item
=
0
;
item
<
npars
;
item
++
)
{
if
(
parTable
[
tableID
].
pars
[
item
].
id
==
code
)
{
if
(
parTable
[
tableID
].
pars
[
item
].
name
)
strcpy
(
name
,
parTable
[
tableID
].
pars
[
item
].
name
);
if
(
parTable
[
tableID
].
pars
[
item
].
longname
)
strcpy
(
longname
,
parTable
[
tableID
].
pars
[
item
].
longname
);
if
(
parTable
[
tableID
].
pars
[
item
].
units
)
strcpy
(
units
,
parTable
[
tableID
].
pars
[
item
].
units
);
break
;
}
}
}
int
tableInqNumber
(
void
)
{
if
(
!
ParTableInit
)
parTableInit
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment