mirror of
https://github.com/Unidata/netcdf-c.git
synced 2025-01-12 15:45:21 +08:00
Corrected 2 windows-specific errors when using Visual Studio:
1. In nc4hdf.c, had a variable declaration located such that Visual Studio complained and threw an error. Moved to head of function. 2. Visual Studio was complaining about variable declarations being made after OCVERIFY/OCDEREF macros.
This commit is contained in:
parent
460ac331e0
commit
71a30406f7
@ -172,6 +172,7 @@ nc4_pg_var1(NC_PG_T pg, NC *nc, int ncid, int varid,
|
||||
int i;
|
||||
size_t *start = NULL;
|
||||
size_t *count = NULL;
|
||||
int res = 0;
|
||||
|
||||
int retval;
|
||||
|
||||
@ -199,7 +200,6 @@ nc4_pg_var1(NC_PG_T pg, NC *nc, int ncid, int varid,
|
||||
}
|
||||
|
||||
/* Get or put this data. */
|
||||
int res = 0;
|
||||
if (pg == GET) {
|
||||
res = nc4_get_vara(nc, ncid, varid, start, count, xtype,
|
||||
is_long, ip);
|
||||
|
7
oc2/oc.c
7
oc2/oc.c
@ -551,9 +551,10 @@ oc_dds_fieldbyname(OCobject link, OCobject ddsnode, const char* name, OCobject*
|
||||
{
|
||||
OCerror err = OC_NOERR;
|
||||
OCnode* node;
|
||||
size_t count,i;
|
||||
OCVERIFY(OC_Node,ddsnode);
|
||||
OCDEREF(OCnode*,node,ddsnode);
|
||||
size_t count,i;
|
||||
|
||||
|
||||
if(!iscontainer(node->octype))
|
||||
return OC_EBADTYPE;
|
||||
@ -965,12 +966,12 @@ oc_data_fieldbyname(OCobject link, OCobject datanode, const char* name, OCobject
|
||||
OCerror err = OC_NOERR;
|
||||
OCstate* state;
|
||||
OCdata* data;
|
||||
size_t count,i;
|
||||
OCobject ddsnode;
|
||||
OCVERIFY(OC_State,link);
|
||||
OCDEREF(OCstate*,state,link);
|
||||
OCVERIFY(OC_Data,datanode);
|
||||
OCDEREF(OCdata*,data,datanode);
|
||||
size_t count,i;
|
||||
OCobject ddsnode;
|
||||
|
||||
/* Get the dds node for this datanode */
|
||||
err = oc_data_ddsnode(link,datanode,&ddsnode);
|
||||
|
Loading…
Reference in New Issue
Block a user