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

gribapi: replaced streamID by streamptr

parent 00dd0f3c
......@@ -36,13 +36,10 @@ const char *gribapiLibraryVersion(void)
}
void gribContainersNew(int streamID)
void gribContainersNew(stream_t * streamptr)
{
stream_t *streamptr;
int editionNumber = 2;
streamptr = stream_to_pointer(streamID);
if ( streamptr->filetype == FILETYPE_GRB ) editionNumber = 1;
#if defined (HAVE_LIBCGRIBEX)
......@@ -87,12 +84,8 @@ void gribContainersNew(int streamID)
}
void gribContainersDelete(int streamID)
void gribContainersDelete(stream_t * streamptr)
{
stream_t *streamptr;
streamptr = stream_to_pointer(streamID);
if ( streamptr->gribContainers )
{
int nvars = streamptr->nvars;
......
......@@ -34,8 +34,8 @@
#define GRIB2_GTYPE_NUMBER 101 /* General Unstructured Grid */
const char *gribapiLibraryVersion(void);
void gribContainersNew(int streamID);
void gribContainersDelete(int streamID);
void gribContainersNew(stream_t * streamptr);
void gribContainersDelete(stream_t * streamptr);
void *gribHandleNew(int editionNumber);
void gribHandleDelete(void *gh);
......
......@@ -505,7 +505,7 @@ char *streamFilename(int streamID)
return (streamptr->filename);
}
static
int cdiInqTimeSize(int streamID)
{
int ntsteps;
......@@ -1174,7 +1174,7 @@ void streamClose(int streamID)
case FILETYPE_GRB2:
{
gribClose(fileID);
gribContainersDelete(streamID);
gribContainersDelete(streamptr);
break;
}
#endif
......@@ -1633,7 +1633,7 @@ void streamReadVar(int streamID, int varID, double *data, int *nmiss)
}
}
static
void stream_write_var(int streamID, int varID, int memtype, const void *data, int nmiss)
{
int filetype;
......@@ -1856,7 +1856,7 @@ void streamReadVarSlice(int streamID, int varID, int levelID, double *data, int
}
}
static
void stream_write_var_slice(int streamID, int varID, int levelID, int memtype, const void *data, int nmiss)
{
int filetype;
......@@ -2219,7 +2219,7 @@ void streamDefVlist(int streamID, int vlistID)
else if ( streamptr->filetype == FILETYPE_GRB ||
streamptr->filetype == FILETYPE_GRB2 )
{
gribContainersNew(streamID);
gribContainersNew(streamptr);
}
}
}
......
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