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

scanTimestep1: set default of rdate to vdate (bug fix).

parent b66592df
2018-02-19 Uwe Schulzweida
* scanTimestep1: set default of rdate to vdate (bug fix)
2018-02-12 Uwe Schulzweida
* varDefZaxis: don't remove default of longname and units
......
......@@ -784,21 +784,11 @@ int cgribexScanTimestep1(stream_t *streamptr)
cdi_generate_vars(streamptr);
if ( fcast )
{
taxisID = taxisCreate(TAXIS_RELATIVE);
taxis->type = TAXIS_RELATIVE;
taxis->rdate = rdate;
taxis->rtime = rtime;
taxis->unit = tunit;
}
else
{
taxisID = taxisCreate(TAXIS_ABSOLUTE);
taxis->type = TAXIS_ABSOLUTE;
taxis->unit = tunit;
}
taxis->unit = tunit;
taxis->type = fcast ? TAXIS_RELATIVE : TAXIS_ABSOLUTE;
taxisID = taxisCreate(taxis->type);
taxis->rdate = rdate;
taxis->rtime = rtime;
taxis->vdate = (int)datetime0.date;
taxis->vtime = (int)datetime0.time;
......
......@@ -292,6 +292,8 @@ void extScanTimestep1(stream_t *streamptr)
taxis->type = TAXIS_ABSOLUTE;
taxis->vdate = (int)datetime0.date;
taxis->vtime = (int)datetime0.time;
taxis->rdate = taxis->vdate;
taxis->rtime = taxis->vtime;
int vlistID = streamptr->vlistID;
vlistDefTaxis(vlistID, taxisID);
......
......@@ -963,20 +963,12 @@ int gribapiScanTimestep1(stream_t * streamptr)
cdi_generate_vars(streamptr);
int taxisID = -1;
if ( fcast )
{
taxisID = taxisCreate(TAXIS_RELATIVE);
taxis->type = TAXIS_RELATIVE;
taxis->rdate = rdate;
taxis->rtime = rtime;
taxis->unit = tunit;
}
else
{
taxisID = taxisCreate(TAXIS_ABSOLUTE);
taxis->type = TAXIS_ABSOLUTE;
}
taxis->unit = tunit;
taxis->type = fcast ? TAXIS_RELATIVE : TAXIS_ABSOLUTE;
taxisID = taxisCreate(taxis->type);
taxis->rdate = rdate;
taxis->rtime = rtime;
taxis->vdate = (int)datetime0.date;
taxis->vtime = (int)datetime0.time;
......
......@@ -805,6 +805,8 @@ void iegScanTimestep1(stream_t *streamptr)
taxis->type = TAXIS_ABSOLUTE;
taxis->vdate = (int)datetime0.date;
taxis->vtime = (int)datetime0.time;
taxis->rdate = taxis->vdate;
taxis->rtime = taxis->vtime;
int vlistID = streamptr->vlistID;
vlistDefTaxis(vlistID, taxisID);
......
......@@ -292,9 +292,11 @@ void srvScanTimestep1(stream_t *streamptr)
cdi_generate_vars(streamptr);
int taxisID = taxisCreate(TAXIS_ABSOLUTE);
taxis->type = TAXIS_ABSOLUTE;
taxis->type = TAXIS_ABSOLUTE;
taxis->vdate = (int)datetime0.date;
taxis->vtime = (int)datetime0.time;
taxis->rdate = taxis->vdate;
taxis->rtime = taxis->vtime;
int vlistID = streamptr->vlistID;
vlistDefTaxis(vlistID, taxisID);
......
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