This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
Hi Chris,
I'm having trouble matching your line numbers with our development release
without a little more context or knowing the version of netCDF you're
debugging. I see that in our current development code we already have:
for (id = 0; id < varp->ndims; id++) {
shapelen += strlen(dims[varp->dims[id]].name) + 1;
}
shape = (char *) emalloc(shapelen);
shape[0] = 0;
for (id = 0; id < varp->ndims; id++) {
strlcat(shape, dims[varp->dims[id]].name, shapelen);
strlcat(shape, id < varp->ndims-1 ? " " : "", shapelen);
}
in our pr_shape(ncvar_t* varp, ncdim_t *dims) function. Is that the code you
were referring to?
--Russ
Russ Rew UCAR Unidata Program
address@hidden http://www.unidata.ucar.edu
Ticket Details
===================
Ticket ID: MNX-138856
Department: Support netCDF
Priority: Normal
Status: Closed