Commit a9596fdc authored by Uwe Schulzweida's avatar Uwe Schulzweida
Browse files

varAddRecord: used max number of bit_per_value for 3D GRIB data

parent 5277760c
2011-10-05 Uwe Schulzweida <Uwe.Schulzweida@zmaw.de>
* stream_cdf::cdfInqContents: check units of hybrid levels
* varAddRecord: used max number of bit_per_value for 3D GRIB data
2011-10-02 Uwe Schulzweida <Uwe.Schulzweida@zmaw.de>
......
......@@ -274,7 +274,6 @@ void varAddRecord(int recID, int param, int gridID, int zaxistype, int lbounds,
{
nvars++;
varID = paramNewEntry(param);
if ( prec > vartable[varID].prec ) vartable[varID].prec = prec;
vartable[varID].gridID = gridID;
vartable[varID].zaxistype = zaxistype;
vartable[varID].ltype = ltype;
......@@ -291,19 +290,21 @@ void varAddRecord(int recID, int param, int gridID, int zaxistype, int lbounds,
if ( vartable[varID].gridID != gridID )
{
char paramstr[32];
cdiParamToString(param, paramstr, sizeof(paramstr));
cdiParamToString(param, paramstr, sizeof(paramstr));
Message("param = %s gridID = %d", paramstr, gridID);
Error("horizontal grid must not change for same param!");
}
if ( vartable[varID].zaxistype != zaxistype )
{
char paramstr[32];
cdiParamToString(param, paramstr, sizeof(paramstr));
cdiParamToString(param, paramstr, sizeof(paramstr));
Message("param = %s zaxistype = %d", paramstr, zaxistype);
Error("zaxistype must not change for same param!");
}
}
if ( prec > vartable[varID].prec ) vartable[varID].prec = prec;
levelID = levelNewEntry(varID, level1, level2);
vartable[varID].levelTable[levelID].recID = recID;
......
Markdown is supported
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