Commit Graph

181 Commits

Author SHA1 Message Date
Robert T. McGibbon
3303ccd519 Fix preprocessor for mingw 2015-12-07 18:08:13 -08:00
dmh
cbb6df3232 Github issue 152: https://github.com/Unidata/netcdf-c/issues/152
User request to have all orphaned DAP2 attributes kept as netcdf
global attributes. This is primarily a change in the oc code
nplus testcase dataset changes.

Result may be inconsistent with netcdf-Java output.
2015-11-29 20:38:12 -07:00
Bas Couwenberg
b8e4161baf Fix inconsistent return type. 2015-11-10 00:19:33 +01:00
Ward Fisher
612b35a84c Merge branch 'master' into cdf-5, in preparation for merging the CDF-5 functionality into the master branch. This will be the key new feature for netcdf 4.4.0. 2015-11-05 13:40:35 -07:00
dmh
7480d7d97d - clean up the dfile.c confusion about NC_64_BIT_OFFSET
- sync oc2 with  master for https://DennisHeimbigner@github.com/Unidata/oc.git
- Cleanup auth.html documentation.
- Cleanup obsolete documentation.
2015-10-24 21:45:13 -06:00
dmh
0f59785f37 sync with base oc library 2015-10-22 15:34:56 -06:00
dmh
a5c8f7c7e3 synch with base oc 2015-10-21 14:53:30 -06:00
dmh
370bd15166 Github issue 134:
Their is an ambiguity in the DAP2 spec.  Section A.2 of the
dap2 spec says:
  "...The backslash character (.\.) MAY be used as
   a single-character quoting mechanism only within
   quoted-string and comment constructs.
      quoted-pair = "\" CHAR
   ..."
The underlying problem was to allow for " chars inside
strings by using \". However, this definition is overbroad.
It is not stated:
1. if the backslash is to be left in the string or not.
2. There is also an unstated, but related issue of what
   to do about e.g. '\n';convert to newline or not.

This change is to conform to libdap and it does the following:
1. The backslash is left in the string
2. Things like \n are left as is and it is assumed that
   higher level code will decide what to do with e.g. \n.
2015-10-20 15:44:26 -06:00
tbeu
e2820e4d8a Fix common typos
Detected by https://github.com/vlajos/misspell_fixer
2015-08-20 11:42:05 +02:00
dmh
859f105005 merge-squash 2015-08-15 16:26:35 -06:00
xantares
c1b56c3f3a fix mingw build
that code path is common to all win32 platforms: msvc & mingw/cygwin
2015-08-03 23:27:41 +02:00
dmh
29386aae47 Synch with base oc 2015-07-15 16:19:14 -06:00
Ward Fisher
7bb61718bf Corrected a couple of minor issues reported by static analysis. 2015-07-10 15:09:14 -06:00
dmh
830f82138a Merge branch 'master' of http://github.com/Unidata/netcdf-c 2015-07-05 19:26:27 -06:00
dmh
c5fe913d54 re: https://github.com/Unidata/netcdf-c/issues/117
It appears the problem is that synth9 was erroneously
included in testing. It involves a nested sequence which
is not translatable. Not sure why it was still there,
but fix is to suppress the test.
2015-07-05 19:26:01 -06:00
Ward Fisher
5721dd302b Corrected a potential null dereference caused by passing '0' to calloc. 2015-06-17 15:42:45 -06:00
Dennis Heimbigner
0d082d79ea synch oc 2015-05-29 17:31:42 -06:00
Ward Fisher
6ed4770e0a Added a typedef int pid_t for Windows platforms, solves a unix compatibility issue. 2015-05-28 10:14:45 -06:00
dmh
be5e3cd606 1. Allow for the user specified rc file via the env variable
DAPRCFILE.  Note that the value of this environment
   variable should be the absolute path of the rc file, not
   the path to its containing directory.
2. fixup testauth.sh and add some new tests
3. synch oc
2015-05-24 17:31:39 -06:00
Ward Fisher
3d9725f7df Corrected a libcurl issue as reported in https://github.com/Unidata/netcdf-c/issues/110 2015-03-17 12:42:14 -06:00
dmh
06a11e51df 1. Allow for the user specified rc file via the env variable
NCRCFILE.  Note that the value of this environment
   variable should be the absolute path of the rc file, not
   the path to its containing directory.
2015-03-03 20:17:27 -07:00
dmh
88f1ac820c 1. synch with oc lib
2. update to add docs/auth.md
2015-03-02 20:26:39 -07:00
Ward Fisher
e6faf3969c Coverity: 1265325, Pointer comparison with string literal. 2015-02-24 10:14:52 -07:00
Ward Fisher
cc260fc9aa Fixed a minor static-analysis reported warning. 2015-02-23 13:25:35 -07:00
Ward Fisher
473163c41a Corrected a couple of static analysis-detected warnings. 2015-02-10 13:04:37 -07:00
Ward Fisher
c659a0e353 Coverity 1264403, Explicit null dereferenced. 2015-01-20 12:44:28 -07:00
Ward Fisher
30149d5e6e Coverity 1264404, missing break in switch. Logically this appears to not be intentional, will revert if this turns out to be incorrect. 2015-01-20 12:40:25 -07:00
Ward Fisher
9cc5898931 Coverity 1264406; char array being compared against NULL. Replaced with a strlen check for the value. 2015-01-20 12:37:57 -07:00
Ward Fisher
f1dcdde045 Coverity 1264401, Buffer not null terminated. 2015-01-20 11:18:27 -07:00
Ward Fisher
35df3d3c95 Coverity 1264407, out-of-bounds access. 2015-01-20 11:12:51 -07:00
Ward Fisher
75c6670416 Resource Leak, Coverity 1264408 2015-01-20 11:09:03 -07:00
Ward Fisher
cb0cb6f674 Resource leak, Coverity 1264409 2015-01-20 11:04:58 -07:00
Ward Fisher
59f8cf19f1 Corrected resource leak, Coverity 1264412 2015-01-20 10:53:42 -07:00
Ward Fisher
69b6935ca5 Removed OCASSERT sizeof(void*) == sizeof(off_t), to see what repercussions are for other tests on 32-bit machines. 2015-01-16 09:18:39 -07:00
dmh
65f78d6a8b 1. synch with oc
2. replace all occurrences of
   'template' with 'pattern'
   since template is reserved in windows.
2015-01-15 14:19:51 -07:00
Ward Fisher
393db0018e Addressed an issue causing MSVC-based builds to fail. See https://github.com/Unidata/netcdf-c/issues/96 2015-01-13 12:44:28 -07:00
Ward Fisher
8487f28277 Removed a stale (potentially) assertion on Dennis' advice to debug an issue. 2015-01-12 12:09:34 -07:00
Ward Fisher
4ecbbe64d5 Fixed a few issues preventing the build from working on MSVC. 2015-01-12 11:05:45 -07:00
dmh
e35a14a85d 1. synch with oc
2. modify oc2/ocrc.c rcfilenames to look for .ocrc before .dodsrc.
3. Modify testauth.sh to avoid using names that might already
   exist for cookies file and netrc file. Still must use .ocrc
   to test for local/home search.
4. Modify testauth.sh to save and restore any file it creates
   that already exists.
2014-12-31 22:29:36 -07:00
dmh
3a559d3f1d Fix occurlflags bug 2014-12-28 15:54:02 -07:00
Ward Fisher
3aa6c969e2 Added an explicit check for CURLOPT_CHUNK_BGN_FUNCTION, otherwise we break the build on systems with libcurl older than version 7.21.0 2014-12-27 22:59:06 -08:00
dmh
20720199c8 1. synch with oc
2. fix ocuri parameter handling
3. add ncdap_test/testuri.sh to test parameter handling.
2014-12-27 20:42:01 -07:00
dmh
c4bc1569f6 Update CMakelist to match Makefile.am in oc2 2014-12-26 13:08:41 -07:00
dmh
7a0a10ec7b add occurlfunctions.[ch] to the dist. 2014-12-26 12:27:54 -07:00
dmh
f423f27693 Sync with oc project.
This supports better authorization
handling for DAP requests, especially redirection
based authorization. I also added a new test case
ncdap_tests/testauth.sh.

Specifically, suppose I have a netrc file /tmp/netrc
containing this.
    machine uat.urs.earthdata.nasa.gov login xxxxxx password yyyyyy
Also suppose I have a .ocrc file containing these lines
    HTTP.COOKIEJAR=/tmp/cookies
    HTTP.NETRC=/tmp/netrc
Assume that .ocrc is in the local directory or HOME.

Then this command should work (assuming a valid login and password).
    ncdump -h "https://54.86.135.31/opendap/data/nc/fnoc1.nc"
2014-12-24 10:22:47 -07:00
dmh
7de1f7bef8 oc synch 2014-11-30 20:30:23 -07:00
dmh
a2e9fb854b synch with base oc library 2014-11-21 16:20:44 -07:00
Ward Fisher
3fadeb8ff1 Fixed several memory leaks reported by static analysis. 2014-10-29 16:09:54 -06:00
Martin Steghöfer
a9012c7bfe Fix segmentation fault when parsing malformed URLs (e.g. "http:/"). 2014-10-05 19:28:03 +02:00
Ward Fisher
c60b45394f Coverity: 711882, leaked storage bug. 2014-10-03 12:57:02 -06:00