Go to file
Dennis Heimbigner 9983b9d911 re e-support UBS-599337
re pull request https://github.com/Unidata/netcdf-c/pull/405
re pull request https://github.com/Unidata/netcdf-c/pull/446

Notes:
1. This branch is a cleanup of the magic.dmh branch.
2. magic.dmh was originally merged, but caused problems with parallel IO.
   It was re-issued as pull request https://github.com/Unidata/netcdf-c/pull/446.
3. This branch + pull request replace any previous pull requests and magic.dmh branch.

Given an otherwise valid netCDF file that has a corrupted header,
the netcdf library currently crashes. Instead, it should return
NC_ENOTNC.

Additionally, the NC_check_file_type code does not do the
forward search required by hdf5 files. It currently only looks
at file position 0 instead of 512, 1024, 2048,... Also, it turns
out that the HDF4 magic number is assumed to always be at the
beginning of the file (unlike HDF5).
The change is localized to libdispatch/dfile.c See
https://support.hdfgroup.org/release4/doc/DSpec_html/DS.pdf

Also, it turns out that the code in NC_check_file_type is duplicated
(mostly) in the function libsrc4/nc4file.c#nc_check_for_hdf.

This branch does the following.
1. Make NC_check_file_type return NC_ENOTNC instead of crashing.
2. Remove nc_check_for_hdf and centralize all file format checking
   NC_check_file_type.
3. Add proper forward search for HDF5 files (but not HDF4 files)
   to look for the magic number at offsets of 0, 512, 1024...
4. Add test tst_hdf5_offset.sh. This tests that hdf5 files with
   an offset are properly recognized. It does so by prefixing
   a legal file with some number of zero bytes: 512, 1024, etc.
5. Off-topic: Added -N flag to ncdump to force a specific output dataset name.
2017-10-24 16:25:09 -06:00
.github
cmake
dap4_test Added CMakeLists.txt to release distribution files. 2017-09-27 13:05:57 -06:00
docs Updated the dependency versions deployed with netcdf on Windows. 2017-10-17 15:33:49 -06:00
examples
h5_test fixed memory problem in tst_h_dimscales 2017-10-23 09:49:38 -06:00
include re e-support UBS-599337 2017-10-24 16:25:09 -06:00
libdap2 Merge remote-tracking branch 'origin/d4tempfile.dmh' into v4.5.0-release-branch 2017-08-07 10:12:36 -06:00
libdap4 Fix dap4 related warnings in https://github.com/Unidata/netcdf-c/issues/501. 2017-10-20 21:17:12 -06:00
libdispatch re e-support UBS-599337 2017-10-24 16:25:09 -06:00
liblib Updated SO version, other little issue with ncdump Makefile.am. 2017-10-17 14:56:22 -06:00
libsrc re e-support UBS-599337 2017-10-24 16:25:09 -06:00
libsrc4 re e-support UBS-599337 2017-10-24 16:25:09 -06:00
libsrcp The files libdispatch/dwinpath.c and include/ncwinpath.h 2017-07-13 10:40:07 -06:00
nc_test re e-support UBS-599337 2017-10-24 16:25:09 -06:00
nc_test4 re e-support UBS-599337 2017-10-24 16:25:09 -06:00
ncdap_test re e-support UBS-599337 2017-10-24 16:25:09 -06:00
ncdump re e-support UBS-599337 2017-10-24 16:25:09 -06:00
ncgen re e-support UBS-599337 2017-10-24 16:25:09 -06:00
ncgen3 ckp 2017-04-14 11:05:30 -06:00
nctest ckp 2017-04-14 11:05:30 -06:00
oc2 Merge branch 'v4.5.0-release-branch' into netrc.dmh 2017-09-25 13:46:32 -06:00
.gitignore more updates due to renaming test_read.c and test_write.c to m4 files 2016-10-13 02:56:50 -05:00
.travis.yml Propegated autoconf options in travis.yml 2016-10-24 17:21:15 -06:00
acinclude.m4 add configure option --enable-relax-coord-bound for issue #243 2016-11-12 23:58:09 -06:00
cf re e-support UBS-599337 2017-10-24 16:25:09 -06:00
cf.cmake re e-support UBS-599337 2017-10-24 16:25:09 -06:00
cmake_uninstall.cmake.in
CMakeInstallation.cmake
CMakeLists.txt Corrected DAP4 and NC4 logic 2017-09-26 15:26:34 -06:00
COMPILE.cmake.txt
config.h.cmake.in Updated an issue with libcurl and dap4 on Windows 2017-09-25 17:38:48 -06:00
config.h.cmake.in.old-works Added a version of config.h.cmake.in, based on the version from 4.4.1.1, that fixes at least one of the tests broken under the more recent re-written config.h.cmake.in. 2017-05-23 16:03:58 -06:00
configure.ac Typo 2017-10-16 10:35:09 -06:00
CONTRIBUTING.md
COPYRIGHT Primary change: add dap4 support 2017-03-08 17:01:10 -07:00
CTestConfig.cmake.in
CTestCustom.cmake Reduced default warning number to accomodate bandwidth limitations on hosted CDash. 2013-09-16 15:21:11 -06:00
dods.m4
FixBundle.cmake.in
INSTALL.md
lib_flags.am Primary change: add dap4 support 2017-03-08 17:01:10 -07:00
libnetcdf.settings.in Wiring in CDF5 configure-time option. 2017-09-13 15:25:40 -06:00
Make0 Primary change: add dap4 support 2017-03-08 17:01:10 -07:00
Makefile.am Merged master, DAP4 support into branch. 2017-04-19 09:29:35 -06:00
mclean Fix pull request https://github.com/Unidata/netcdf-c/pull/374 (dap4.dmh) 2017-04-03 21:39:44 -06:00
nc-config.cmake.in Fixed shell script typo. 2017-10-16 10:06:46 -06:00
nc-config.in Corrected issue with nc-config generatred by autotools. 2017-10-16 10:30:47 -06:00
netcdf.pc.in
netCDFConfig.cmake.in Primary change: add dap4 support 2017-03-08 17:01:10 -07:00
PostInstall.cmake
postinstall.sh.in Fix pull request https://github.com/Unidata/netcdf-c/pull/374 (dap4.dmh) 2017-04-03 21:39:44 -06:00
README.md
RELEASE_NOTES.md Updated release notes in support of https://github.com/Unidata/netcdf-c/pulls/511 2017-10-23 15:54:17 -06:00
test_common.in Fix for github issue https://github.com/Unidata/netcdf-c/issues/310. 2017-06-28 13:51:01 -06:00
test_prog.c
test_prog.f90
test_prog.F
test-driver-verbose Fix pull request https://github.com/Unidata/netcdf-c/pull/374 (dap4.dmh) 2017-04-03 21:39:44 -06:00
wjna

Unidata NetCDF

Build Status Coverity Scan Build Status

About

The Unidata network Common Data Form (netCDF) is an interface for scientific data access and a freely-distributed software library that provides an implementation of the interface. The netCDF library also defines a machine-independent format for representing scientific data. Together, the interface, library, and format support the creation, access, and sharing of scientific data. The current netCDF software provides C interfaces for applications and data. Separate software distributions available from Unidata provide Java, Fortran, Python, and C++ interfaces. They have been tested on various common platforms.

Properties

NetCDF files are self-describing, network-transparent, directly accessible, and extendible. Self-describing means that a netCDF file includes information about the data it contains. Network-transparent means that a netCDF file is represented in a form that can be accessed by computers with different ways of storing integers, characters, and floating-point numbers. Direct-access means that a small subset of a large dataset may be accessed efficiently, without first reading through all the preceding data. Extendible means that data can be appended to a netCDF dataset without copying it or redefining its structure.

Use

NetCDF is useful for supporting access to diverse kinds of scientific data in heterogeneous networking environments and for writing application software that does not depend on application-specific formats. For information about a variety of analysis and display packages that have been developed to analyze and display data in netCDF form, see

More information

For more information about netCDF, see

Latest releases

You can obtain a copy of the latest released version of netCDF software for various languages:

Copyright and licensing information can be found here, as well as in the COPYRIGHT file accompanying the software

Installation

To install the netCDF-C software, please see the file INSTALL in the netCDF-C distribution, or the (usually more up-to-date) document:

Documentation

A language-independent User's Guide for netCDF, and some other language-specific user-level documents are available from:

A mailing list, netcdfgroup@unidata.ucar.edu, exists for discussion of the netCDF interface and announcements about netCDF bugs, fixes, and enhancements. For information about how to subscribe, see the URL

Feedback

We appreciate feedback from users of this package. Please send comments, suggestions, and bug reports to support-netcdf@unidata.ucar.edu.