Skip to content
Snippets Groups Projects
Commit 87d79808 authored by Thomas Jahns's avatar Thomas Jahns :cartwheel: Committed by Sergey Kosukhin
Browse files

Narrow scope of variables.

parent c7d15f2f
No related branches found
No related tags found
2 merge requests!34Version 2.2.0,!13Consolidation with CDI-PIO (develop)
......@@ -770,7 +770,6 @@ cdfDefIrregularGridCommon(stream_t *streamptr, int gridID, size_t xsize, size_t
int xdimID = CDI_UNDEFID;
int ydimID = CDI_UNDEFID;
int ncxvarid = CDI_UNDEFID, ncyvarid = CDI_UNDEFID, ncavarid = CDI_UNDEFID;
int ncbxvarid = CDI_UNDEFID, ncbyvarid = CDI_UNDEFID;
const int fileID = streamptr->fileID;
bool switchNCMode = streamptr->ncmode == 2;
if (switchNCMode)
......@@ -867,6 +866,7 @@ cdfDefIrregularGridCommon(stream_t *streamptr, int gridID, size_t xsize, size_t
const size_t xaxisnameLen = strlen(xaxisname);
xaxisname[xaxisnameLen] = '_';
memcpy(xaxisname + xaxisnameLen + 1, bndsName, sizeof(bndsName));
int ncbxvarid;
cdf_def_var(fileID, xaxisname, xtype, ndims, dimIDs, &ncbxvarid);
cdfGridCompress(fileID, ncbxvarid, gridsize, streamptr->filetype, streamptr->comptype, chunks);
......@@ -897,6 +897,7 @@ cdfDefIrregularGridCommon(stream_t *streamptr, int gridID, size_t xsize, size_t
const size_t yaxisnameLen = strlen(yaxisname);
yaxisname[yaxisnameLen] = '_';
memcpy(yaxisname + yaxisnameLen + 1, bndsName, sizeof(bndsName));
int ncbyvarid;
cdf_def_var(fileID, yaxisname, xtype, ndims, dimIDs, &ncbyvarid);
cdfGridCompress(fileID, ncbyvarid, gridsize, streamptr->filetype, streamptr->comptype, chunks);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment