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

No commit message

No commit message
parent db45f592
......@@ -89,6 +89,7 @@ int cdfOpenFile(const char *filename, const char *mode, int version)
#if defined (HAVE_LIBNETCDF)
int fmode;
int writemode = NC_CLOBBER;
int readmode = NC_NOWRITE;
int status;
if ( filename == NULL )
......@@ -100,7 +101,7 @@ int cdfOpenFile(const char *filename, const char *mode, int version)
case 'r':
case 'R':
fmode = 'r';
status = cdf_open(filename, NC_NOWRITE, &ncid);
status = cdf_open(filename, readmode, &ncid);
if ( status > 0 && ncid < 0 ) ncid = CDI_ESYSTEM;
break;
case 'w':
......
!
! Fortran interface for CDI library version 1.1.1
! Fortran interface for CDI library version 1.2.0
!
INTEGER CDI_UNDEFID
......
......@@ -2202,8 +2202,8 @@ int cdfDefVar(int streamID, int varID)
{
xid = streamptr->xdimID[gridindex];
yid = streamptr->ydimID[gridindex];
cdf_inq_dimlen(fileID, xid, &xsize);
cdf_inq_dimlen(fileID, yid, &ysize);
if ( xid != UNDEFID ) cdf_inq_dimlen(fileID, xid, &xsize);
if ( yid != UNDEFID ) cdf_inq_dimlen(fileID, yid, &ysize);
}
zaxisindex = vlistZaxisIndex(vlistID, zaxisID);
......
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