Commit 97e8c6ab authored by Thomas Jahns's avatar Thomas Jahns 🤸
Browse files

Fix missing const for unchanged argument pointee.

parent 9a8bc322
......@@ -941,7 +941,7 @@ struct varDefZAxisSearchState
int zaxistype;
int nlevels;
int lbounds;
double *levels;
const double *levels;
const char *longname;
const char *units;
int ltype;
......@@ -964,23 +964,19 @@ varDefZAxisSearch(int id, void *res, void *data)
}
int varDefZaxis(int vlistID, int zaxistype, int nlevels, double *levels, int lbounds,
double *levels1, double *levels2, int vctsize, double *vct, char *name,
char *longname, const char *units, int prec, int mode, int ltype1)
int varDefZaxis(int vlistID, int zaxistype, int nlevels, const double *levels, int lbounds,
const double *levels1, const double *levels2, int vctsize, const double *vct, char *name,
const char *longname, const char *units, int prec, int mode, int ltype1)
{
/*
mode: 0 search in vlist and zaxis table
1 search in zaxis table
*/
int zaxisdefined = 0;
int nzaxis;
int zaxisID = UNDEFID;
int zaxisglobdefined = 0;
vlist_t *vlistptr;
vlistptr = vlist_to_pointer(vlistID);
nzaxis = vlistptr->nzaxis;
vlist_t *vlistptr = vlist_to_pointer(vlistID);
int nzaxis = vlistptr->nzaxis;
if ( mode == 0 )
for ( int index = 0; index < nzaxis; index++ )
......
......@@ -15,9 +15,9 @@ void varAddRecord(int recID, int param, int gridID, int zaxistype, int lbounds,
void varDefVCT(size_t vctsize, double *vctptr);
void varDefZAxisReference(int nlev, int nvgrid, unsigned char uuid[CDI_UUID_SIZE]);
int varDefZaxis(int vlistID, int zaxistype, int nlevels, double *levels, int lbounds,
double *levels1, double *levels2, int vctsize, double *vct, char *name,
char *longname, const char *units, int prec, int mode, int ltype);
int varDefZaxis(int vlistID, int zaxistype, int nlevels, const double *levels, int lbounds,
const double *levels1, const double *levels2, int vctsize, const double *vct, char *name,
const char *longname, const char *units, int prec, int mode, int ltype);
void varDefMissval(int varID, double missval);
void varDefCompType(int varID, int comptype);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment