diff --git a/libdap2/dapattr.c b/libdap2/dapattr.c index 87dd643bbd..4bd39c28fe 100644 --- a/libdap2/dapattr.c +++ b/libdap2/dapattr.c @@ -87,16 +87,20 @@ fprintf(stderr,"%s.dimname=%s\n",node->ocname,node->dodsspecial.dimname); } else node->dodsspecial.dimname = NULL; } else if(strcmp(ocname,"DODS.Unlimited_Dimension")==0 || strcmp(ocname,"DODS_EXTRA.Unlimited_Dimension")==0) { - if(values != NULL) { - if(nccomm->cdf.recorddimname != NULL) + char* val0 = NULL; + if(values != NULL) + val0 = values[0]; + if(val0 != NULL) { + if(nccomm->cdf.recorddimname != NULL) { + if(strcmp(nccomm->cdf.recorddimname,val0)!=0) nclog(NCLOGWARN,"Duplicate DODS_EXTRA:Unlimited_Dimension specifications"); - else + } else { nccomm->cdf.recorddimname = nulldup(values[0]); #ifdef DEBUG fprintf(stderr,"%s.Unlimited_Dimension=%s\n",node->ocname,nccomm->cdf.recorddimname); #endif + } } - } } /* clean up */ @@ -115,7 +119,13 @@ fprintf(stderr,"%s.Unlimited_Dimension=%s\n",node->ocname,nccomm->cdf.recorddimn return THROW(ncstat); } -/* Build an NCattribute */ +/* +Build an NCattribute +from a DAP attribute. +As of Jun 27, 2017, we modify +to suppress nul characters and terminate +the name at the first nul. +*/ static NCerror buildattribute(char* name, nc_type ptype, size_t nvalues, char** values, NCattribute** attp) @@ -130,9 +140,10 @@ buildattribute(char* name, nc_type ptype, att->etype = ptype; att->values = nclistnew(); - for(i=0;ivalues,(void*)nulldup(values[i])); - + for(i=0;ivalues,(void*)copy); + } if(attp) *attp = att; else free(att); @@ -399,14 +410,19 @@ fprintf(stderr,"%s.dimname=%s\n",dds->ocname,dds->dodsspecial.dimname); #endif } else dds->dodsspecial.dimname = NULL; } else if(strcmp(dodsname,"Unlimited_Dimension")==0) { - if(nccomm->cdf.recorddimname != NULL) { - nclog(NCLOGWARN,"Duplicate DODS_EXTRA:Unlimited_Dimension specifications"); - } else if(nclistlength(stringvalues) > 0) { - char* stringval = (char*)nclistget(stringvalues,0); - nccomm->cdf.recorddimname = nulldup(stringval); + char* stringval = NULL; + if(nclistlength(stringvalues) > 0) + stringval = (char*)nclistget(stringvalues,0); + if(stringval != NULL) { + if(nccomm->cdf.recorddimname != NULL) { + if(strcmp(stringval,nccomm->cdf.recorddimname) != 0) + nclog(NCLOGWARN,"Duplicate DODS_EXTRA:Unlimited_Dimension specifications"); + } else { + nccomm->cdf.recorddimname = nulldup(stringval); #ifdef DEBUG fprintf(stderr,"%s.Unlimited_Dimension=%s\n",dds->ocname,nccomm->cdf.recorddimname); #endif + } } } /* else ignore */ nullfree(dodsname); diff --git a/libdap2/dapdebug.c b/libdap2/dapdebug.c index 558b6533a3..e8e4760042 100644 --- a/libdap2/dapdebug.c +++ b/libdap2/dapdebug.c @@ -14,7 +14,10 @@ int ncdap3debug = 0; #ifdef CATCHERROR /* Place breakpoint here to catch errors close to where they occur*/ int -dapbreakpoint(int err) {return err;} +dapbreakpoint(int err) +{ + return err; +} int dapthrow(int err) diff --git a/libdap2/nccommon.h b/libdap2/nccommon.h index 2f123767ac..5fc5e6e584 100644 --- a/libdap2/nccommon.h +++ b/libdap2/nccommon.h @@ -112,6 +112,7 @@ typedef struct NCCDF { size_t smallsizelimit; /* what constitutes a small object? */ size_t totalestimatedsize; const char* separator; /* constant; do not free */ + /* Following fields should be set from the unconstrained dds only */ /* global string dimension */ struct CDFnode* globalstringdim; char* recorddimname; /* From DODS_EXTRA */ diff --git a/libdap2/ncd2dispatch.c b/libdap2/ncd2dispatch.c index cfd50405fb..53ba6b2b49 100644 --- a/libdap2/ncd2dispatch.c +++ b/libdap2/ncd2dispatch.c @@ -6,6 +6,9 @@ #include "dapincludes.h" #include "ncd2dispatch.h" #include "ncoffsets.h" +#ifdef DEBUG2 +#include "dapdump.h" +#endif #ifdef _MSC_VER #include @@ -2020,7 +2023,7 @@ fetchpatternmetadata(NCDAPCOMMON* dapcomm) if(ncstat != NC_NOERR) {THROWCHK(ncstat); goto done;} } -#ifdef DEBUG +#ifdef DEBUG2 fprintf(stderr,"full pattern:\n%s",dumptree(dapcomm->cdf.fullddsroot)); #endif @@ -2061,7 +2064,7 @@ fetchconstrainedmetadata(NCDAPCOMMON* dapcomm) if(ncstat) goto fail; } -#ifdef DEBUG +#ifdef DEBUG2 fprintf(stderr,"constrained:\n%s",dumptree(dapcomm->cdf.ddsroot)); #endif @@ -2071,7 +2074,6 @@ fprintf(stderr,"constrained:\n%s",dumptree(dapcomm->cdf.ddsroot)); dapcomm->oc.ocdasroot); if(ncstat != NC_NOERR) {THROWCHK(ncstat); goto fail;} } - /* map the constrained DDS to the unconstrained DDS */ ncstat = mapnodes(dapcomm->cdf.ddsroot,dapcomm->cdf.fullddsroot); if(ncstat) goto fail; diff --git a/ncdap_test/expected3/123.nc.dmp b/ncdap_test/expected3/123.nc.dmp index 84ba36a848..448818ae78 100644 --- a/ncdap_test/expected3/123.nc.dmp +++ b/ncdap_test/expected3/123.nc.dmp @@ -7,8 +7,7 @@ dimensions: variables: short l(l) ; char bears(i, j, maxStrlen64) ; - bears:act = "text string\n", - "\t123" ; + bears:act = "text string\\012\\011123" ; bears:acs = -40s ; bears:acl = 17000 ; bears:acf = -2.f, 1.f, 0.f ; @@ -20,9 +19,7 @@ variables: double cross(i, j) ; // global attributes: - :history = "This is an example of a multi-line global\n", - "attribute. It could be used for representing the\n", - "processing history of the data, for example." ; + :history = "This is an example of a multi-line global\\012attribute. It could be used for representing the\\012processing history of the data, for example." ; :DODS_EXTRA.Unlimited_Dimension = "k" ; data: diff --git a/ncdap_test/expected3/123bears.nc.dmp b/ncdap_test/expected3/123bears.nc.dmp index 9379de3e25..4611b98b8d 100644 --- a/ncdap_test/expected3/123bears.nc.dmp +++ b/ncdap_test/expected3/123bears.nc.dmp @@ -7,8 +7,7 @@ dimensions: variables: short l(l) ; char bears(i, j, maxStrlen64) ; - bears:act = "text string\n", - "\t123" ; + bears:act = "text string\\012\\011123" ; bears:acs = -40s ; bears:acl = 17000 ; bears:acf = -2.f, 1.f, 0.f ; @@ -20,9 +19,7 @@ variables: double cross(i, j) ; // global attributes: - :history = "This is an example of a multi-line global\n", - "attribute. It could be used for representing the\n", - "processing history of the data, for example." ; + :history = "This is an example of a multi-line global\\012attribute. It could be used for representing the\\012processing history of the data, for example." ; :DODS_EXTRA.Unlimited_Dimension = "k" ; data: diff --git a/ncdap_test/expected3/1990-S1700101.HDF.WVC_Lat.dmp b/ncdap_test/expected3/1990-S1700101.HDF.WVC_Lat.dmp index 05e6fc65b3..5b482dffa4 100644 --- a/ncdap_test/expected3/1990-S1700101.HDF.WVC_Lat.dmp +++ b/ncdap_test/expected3/1990-S1700101.HDF.WVC_Lat.dmp @@ -14,29 +14,284 @@ variables: NSCAT%20Rev%2017.WVC_Lat:valid_range = -6281s, 8051s ; // global attributes: - :Producer_Agency = "NASA" ; - :Producer_Institution = "JPL" ; - :Sensor_Name = "NSCAT" ; - :Project_ID = "NSCAT" ; - :SIS_ID = "697-512-23/1994-08-29" ; - :Build_ID = "SciSim 3.0" ; - :ADEOS_Data_Package_ID = "SIMULATED DATA PRODUCT TEST" ; - :ADEOS_Data_Package_Type = "S" ; - :Product_Creation_Time = "1995-278T23:30:04.000" ; - :Data_Type = "L17" ; - :Data_Status = "COMPLETE" ; + :Producer_Agency = "NASA\\000" ; + :Producer_Institution = "JPL\\000" ; + :Sensor_Name = "NSCAT\\000" ; + :Project_ID = "NSCAT\\000" ; + :SIS_ID = "697-512-23/1994-08-29\\000" ; + :Build_ID = "SciSim 3.0\\000" ; + :ADEOS_Data_Package_ID = "SIMULATED DATA PRODUCT TEST\\000" ; + :ADEOS_Data_Package_Type = "S\\000" ; + :Product_Creation_Time = "1995-278T23:30:04.000\\000" ; + :Data_Type = "L17\\000" ; + :Data_Status = "COMPLETE\\000" ; :First_Rev_Number = 101 ; - :First_Rev_Eq_Crossing_Time = "1996-215T01:31:07.223" ; + :First_Rev_Eq_Crossing_Time = "1996-215T01:31:07.223\\000" ; :First_Rev_Eq_Crossing_Lon = 54.952f ; - :First_Data_Time = "1996-215T01:13:28.456" ; - :Last_Data_Time = "1996-215T02:40:22.631" ; + :First_Data_Time = "1996-215T01:13:28.456\\000" ; + :Last_Data_Time = "1996-215T02:40:22.631\\000" ; :Num_Expected_Output_Records = 558 ; :Num_Actual_Output_Records = 558 ; - :HDF_Build_ID = "JPL D-xxxxx 12/15/94" ; - :HDF_SIS_ID = "JPL D-12059 12/15/94" ; - :HDF_Conversion_Organization = "JPL PO.DAAC" ; + :HDF_Build_ID = "JPL D-xxxxx 12/15/94\\000" ; + :HDF_SIS_ID = "JPL D-12059 12/15/94\\000" ; + :HDF_Conversion_Organization = "JPL PO.DAAC\\000" ; :HDF_Conversion_Time = "1996-047T11:13:05 " ; - :Data_Format_Type = "HDF" ; + :Data_Format_Type = "HDF\\000" ; + :WVC_Lat_dim_0.name = "row" ; + :WVC_Lat_dim_0.long_name = "WVC row index" ; + :WVC_Lat_dim_1.name = "WVC" ; + :WVC_Lat_dim_1.long_name = "WVC index within a row" ; + :WVC_Lon.long_name = "longitude" ; + :WVC_Lon.units = "deg" ; + :WVC_Lon.scale_factor = 0.01 ; + :WVC_Lon.scale_factor_err = 0. ; + :WVC_Lon.add_offset = 0. ; + :WVC_Lon.add_offset_err = 0. ; + :WVC_Lon.calibrated_nt = 22 ; + :WVC_Lon.valid_range = 0s, -29545s ; + :WVC_Lon_dim_0.name = "row" ; + :WVC_Lon_dim_0.long_name = "WVC row index" ; + :WVC_Lon_dim_1.name = "WVC" ; + :WVC_Lon_dim_1.long_name = "WVC index within a row" ; + :Num_Sigma0.long_name = "The total number of sigma-0 measurements" ; + :Num_Sigma0.units = "counts" ; + :Num_Sigma0.scale_factor = 1. ; + :Num_Sigma0.scale_factor_err = 0. ; + :Num_Sigma0.add_offset = 0. ; + :Num_Sigma0.add_offset_err = 0. ; + :Num_Sigma0.calibrated_nt = 21 ; + :Num_Sigma0.valid_range = 0, 21 ; + :Num_Sigma0_dim_0.name = "row" ; + :Num_Sigma0_dim_0.long_name = "WVC row index" ; + :Num_Sigma0_dim_1.name = "WVC" ; + :Num_Sigma0_dim_1.long_name = "WVC index within a row" ; + :Num_Good_Sigma0.long_name = "The number of good sigma-0 measurements" ; + :Num_Good_Sigma0.units = "counts" ; + :Num_Good_Sigma0.scale_factor = 1. ; + :Num_Good_Sigma0.scale_factor_err = 0. ; + :Num_Good_Sigma0.add_offset = 0. ; + :Num_Good_Sigma0.add_offset_err = 0. ; + :Num_Good_Sigma0.calibrated_nt = 21 ; + :Num_Good_Sigma0.valid_range = 0, 21 ; + :Num_Good_Sigma0_dim_0.name = "row" ; + :Num_Good_Sigma0_dim_0.long_name = "WVC row index" ; + :Num_Good_Sigma0_dim_1.name = "WVC" ; + :Num_Good_Sigma0_dim_1.long_name = "WVC index within a row" ; + :Num_Beam_12.long_name = "The total number of sigma-0s received from beam 1 or 2" ; + :Num_Beam_12.units = "counts" ; + :Num_Beam_12.scale_factor = 1. ; + :Num_Beam_12.scale_factor_err = 0. ; + :Num_Beam_12.add_offset = 0. ; + :Num_Beam_12.add_offset_err = 0. ; + :Num_Beam_12.calibrated_nt = 21 ; + :Num_Beam_12.valid_range = 0, 6 ; + :Num_Beam_12_dim_0.name = "row" ; + :Num_Beam_12_dim_0.long_name = "WVC row index" ; + :Num_Beam_12_dim_1.name = "WVC" ; + :Num_Beam_12_dim_1.long_name = "WVC index within a row" ; + :Num_Beam_34.long_name = "The total number of sigma-0s received from beam 3 or 4" ; + :Num_Beam_34.units = "counts" ; + :Num_Beam_34.scale_factor = 1. ; + :Num_Beam_34.scale_factor_err = 0. ; + :Num_Beam_34.add_offset = 0. ; + :Num_Beam_34.add_offset_err = 0. ; + :Num_Beam_34.calibrated_nt = 21 ; + :Num_Beam_34.valid_range = 0, 6 ; + :Num_Beam_34_dim_0.name = "row" ; + :Num_Beam_34_dim_0.long_name = "WVC row index" ; + :Num_Beam_34_dim_1.name = "WVC" ; + :Num_Beam_34_dim_1.long_name = "WVC index within a row" ; + :Num_Beam_56.long_name = "The total number of sigma-0s received from beam 5 or 6" ; + :Num_Beam_56.units = "counts" ; + :Num_Beam_56.scale_factor = 1. ; + :Num_Beam_56.scale_factor_err = 0. ; + :Num_Beam_56.add_offset = 0. ; + :Num_Beam_56.add_offset_err = 0. ; + :Num_Beam_56.calibrated_nt = 21 ; + :Num_Beam_56.valid_range = 0, 6 ; + :Num_Beam_56_dim_0.name = "row" ; + :Num_Beam_56_dim_0.long_name = "WVC row index" ; + :Num_Beam_56_dim_1.name = "WVC" ; + :Num_Beam_56_dim_1.long_name = "WVC index within a row" ; + :Num_Beam_78.long_name = "The total number of sigma-0s received from beam 7 or 8" ; + :Num_Beam_78.units = "counts" ; + :Num_Beam_78.scale_factor = 1. ; + :Num_Beam_78.scale_factor_err = 0. ; + :Num_Beam_78.add_offset = 0. ; + :Num_Beam_78.add_offset_err = 0. ; + :Num_Beam_78.calibrated_nt = 21 ; + :Num_Beam_78.valid_range = 0, 6 ; + :Num_Beam_78_dim_0.name = "row" ; + :Num_Beam_78_dim_0.long_name = "WVC row index" ; + :Num_Beam_78_dim_1.name = "WVC" ; + :Num_Beam_78_dim_1.long_name = "WVC index within a row" ; + :WVC_Quality_Flag.long_name = "WVC Quality Flag" ; + :WVC_Quality_Flag.scale_factor = 1. ; + :WVC_Quality_Flag.scale_factor_err = 0. ; + :WVC_Quality_Flag.add_offset = 0. ; + :WVC_Quality_Flag.add_offset_err = 0. ; + :WVC_Quality_Flag.calibrated_nt = 21 ; + :WVC_Quality_Flag.valid_range = 0, 3 ; + :WVC_Quality_Flag_dim_0.name = "row" ; + :WVC_Quality_Flag_dim_0.long_name = "WVC row index" ; + :WVC_Quality_Flag_dim_1.name = "WVC" ; + :WVC_Quality_Flag_dim_1.long_name = "WVC index within a row" ; + :Cen_Lat.long_name = "The center geodetic latitude of a sigma-0 cell" ; + :Cen_Lat.units = "deg" ; + :Cen_Lat.scale_factor = 0.001 ; + :Cen_Lat.scale_factor_err = 0. ; + :Cen_Lat.add_offset = 0. ; + :Cen_Lat.add_offset_err = 0. ; + :Cen_Lat.calibrated_nt = 24 ; + :Cen_Lat.valid_range = -62862, 80490 ; + :Cen_Lat_dim_0.name = "row" ; + :Cen_Lat_dim_0.long_name = "WVC row index" ; + :Cen_Lat_dim_1.name = "WVC" ; + :Cen_Lat_dim_1.long_name = "WVC index within a row" ; + :Cen_Lat_dim_2.name = "Sigma0-Dimension" ; + :Cen_Lat_dim_2.long_name = "Sigma0 position index" ; + :Cen_Lon.long_name = "The center longitude of a sigma-0 cell" ; + :Cen_Lon.units = "deg" ; + :Cen_Lon.scale_factor = 0.001 ; + :Cen_Lon.scale_factor_err = 0. ; + :Cen_Lon.add_offset = 0. ; + :Cen_Lon.add_offset_err = 0. ; + :Cen_Lon.calibrated_nt = 25 ; + :Cen_Lon.valid_range = 0, 359997 ; + :Cen_Lon_dim_0.name = "row" ; + :Cen_Lon_dim_0.long_name = "WVC row index" ; + :Cen_Lon_dim_1.name = "WVC" ; + :Cen_Lon_dim_1.long_name = "WVC index within a row" ; + :Cen_Lon_dim_2.name = "Sigma0-Dimension" ; + :Cen_Lon_dim_2.long_name = "Sigma0 position index" ; + :Cell_Azimuth.long_name = "The center longitude of a sigma-0 cell" ; + :Cell_Azimuth.units = "deg" ; + :Cell_Azimuth.scale_factor = 0.01 ; + :Cell_Azimuth.scale_factor_err = 0. ; + :Cell_Azimuth.add_offset = 0. ; + :Cell_Azimuth.add_offset_err = 0. ; + :Cell_Azimuth.calibrated_nt = 23 ; + :Cell_Azimuth.valid_range = 0s, -30784s ; + :Cell_Azimuth_dim_0.name = "row" ; + :Cell_Azimuth_dim_0.long_name = "WVC row index" ; + :Cell_Azimuth_dim_1.name = "WVC" ; + :Cell_Azimuth_dim_1.long_name = "WVC index within a row" ; + :Cell_Azimuth_dim_2.name = "Sigma0-Dimension" ; + :Cell_Azimuth_dim_2.long_name = "Sigma0 position index" ; + :Incidence_Angle.long_name = "The angle between the local normal vector and cell center direction vector" ; + :Incidence_Angle.units = "deg" ; + :Incidence_Angle.scale_factor = 0.01 ; + :Incidence_Angle.scale_factor_err = 0. ; + :Incidence_Angle.add_offset = 0. ; + :Incidence_Angle.add_offset_err = 0. ; + :Incidence_Angle.calibrated_nt = 23 ; + :Incidence_Angle.valid_range = 0s, 6259s ; + :Incidence_Angle_dim_0.name = "row" ; + :Incidence_Angle_dim_0.long_name = "WVC row index" ; + :Incidence_Angle_dim_1.name = "WVC" ; + :Incidence_Angle_dim_1.long_name = "WVC index within a row" ; + :Incidence_Angle_dim_2.name = "Sigma0-Dimension" ; + :Incidence_Angle_dim_2.long_name = "Sigma0 position index" ; + :Sigma0.long_name = "The sigma-0 measurement corresponding to each WVC" ; + :Sigma0.units = "dB" ; + :Sigma0.scale_factor = 0.01 ; + :Sigma0.scale_factor_err = 0. ; + :Sigma0.add_offset = 0. ; + :Sigma0.add_offset_err = 0. ; + :Sigma0.calibrated_nt = 22 ; + :Sigma0.valid_range = -6069s, 344s ; + :Sigma0_dim_0.name = "row" ; + :Sigma0_dim_0.long_name = "WVC row index" ; + :Sigma0_dim_1.name = "WVC" ; + :Sigma0_dim_1.long_name = "WVC index within a row" ; + :Sigma0_dim_2.name = "Sigma0-Dimension" ; + :Sigma0_dim_2.long_name = "Sigma0 position index" ; + :Coeff_A.long_name = "The coefficient (alpha) of sigma-0 squared in the sigma-0 variance equation" ; + :Coeff_A.scale_factor = 1.e-05 ; + :Coeff_A.scale_factor_err = 0. ; + :Coeff_A.add_offset = 0. ; + :Coeff_A.add_offset_err = 0. ; + :Coeff_A.calibrated_nt = 23 ; + :Coeff_A.valid_range = 0s, 5235s ; + :Coeff_A_dim_0.name = "row" ; + :Coeff_A_dim_0.long_name = "WVC row index" ; + :Coeff_A_dim_1.name = "WVC" ; + :Coeff_A_dim_1.long_name = "WVC index within a row" ; + :Coeff_A_dim_2.name = "Sigma0-Dimension" ; + :Coeff_A_dim_2.long_name = "Sigma0 position index" ; + :Coeff_B.long_name = "The coefficient (beta) of sigma-0 in the sigma-0 variance equation" ; + :Coeff_B.scale_factor = 1.e-07 ; + :Coeff_B.scale_factor_err = 0. ; + :Coeff_B.add_offset = 0. ; + :Coeff_B.add_offset_err = 0. ; + :Coeff_B.calibrated_nt = 23 ; + :Coeff_B.valid_range = 0s, 793s ; + :Coeff_B_dim_0.name = "row" ; + :Coeff_B_dim_0.long_name = "WVC row index" ; + :Coeff_B_dim_1.name = "WVC" ; + :Coeff_B_dim_1.long_name = "WVC index within a row" ; + :Coeff_B_dim_2.name = "Sigma0-Dimension" ; + :Coeff_B_dim_2.long_name = "Sigma0 position index" ; + :Coeff_C.long_name = "The coefficient (gamma) representing the constant term in the sigma-0 variance equation" ; + :Coeff_C.scale_factor = 1.e-09 ; + :Coeff_C.scale_factor_err = 0. ; + :Coeff_C.add_offset = 0. ; + :Coeff_C.add_offset_err = 0. ; + :Coeff_C.calibrated_nt = 23 ; + :Coeff_C.valid_range = 0s, 61s ; + :Coeff_C_dim_0.name = "row" ; + :Coeff_C_dim_0.long_name = "WVC row index" ; + :Coeff_C_dim_1.name = "WVC" ; + :Coeff_C_dim_1.long_name = "WVC index within a row" ; + :Coeff_C_dim_2.name = "Sigma0-Dimension" ; + :Coeff_C_dim_2.long_name = "Sigma0 position index" ; + :Sigma0_Quality_Flag.long_name = "Bit flags indicating the quality of sigma-0 measurements" ; + :Sigma0_Quality_Flag.valid_range = 0s, 1s ; + :Sigma0_Quality_Flag_dim_0.name = "row" ; + :Sigma0_Quality_Flag_dim_0.long_name = "WVC row index" ; + :Sigma0_Quality_Flag_dim_1.name = "WVC" ; + :Sigma0_Quality_Flag_dim_1.long_name = "WVC index within a row" ; + :Sigma0_Quality_Flag_dim_2.name = "Sigma0-Dimension" ; + :Sigma0_Quality_Flag_dim_2.long_name = "Sigma0 position index" ; + :K_Polar.long_name = "The polarization index to the model function table" ; + :K_Polar.scale_factor = 1. ; + :K_Polar.scale_factor_err = 0. ; + :K_Polar.add_offset = 0. ; + :K_Polar.add_offset_err = 0. ; + :K_Polar.calibrated_nt = 21 ; + :K_Polar.valid_range = 0, 2 ; + :K_Polar_dim_0.name = "row" ; + :K_Polar_dim_0.long_name = "WVC row index" ; + :K_Polar_dim_1.name = "WVC" ; + :K_Polar_dim_1.long_name = "WVC index within a row" ; + :K_Polar_dim_2.name = "Sigma0-Dimension" ; + :K_Polar_dim_2.long_name = "Sigma0 position index" ; + :Sigma0_Usable_Flag_1.long_name = "Eight bit flags indicating whether or not the first set of eight sigma-0 measurements is usable for wind retrieval" ; + :Sigma0_Usable_Flag_1.valid_range = 0, 0 ; + :Sigma0_Usable_Flag_1_dim_0.name = "row" ; + :Sigma0_Usable_Flag_1_dim_0.long_name = "WVC row index" ; + :Sigma0_Usable_Flag_1_dim_1.name = "WVC" ; + :Sigma0_Usable_Flag_1_dim_1.long_name = "WVC index within a row" ; + :Sigma0_Usable_Flag_2.long_name = "Eight bit flags indicating whether or not the second set of eight sigma-0 measurements is usable for wind retrieval" ; + :Sigma0_Usable_Flag_2.valid_range = 0, 0 ; + :Sigma0_Usable_Flag_2_dim_0.name = "row" ; + :Sigma0_Usable_Flag_2_dim_0.long_name = "WVC row index" ; + :Sigma0_Usable_Flag_2_dim_1.name = "WVC" ; + :Sigma0_Usable_Flag_2_dim_1.long_name = "WVC index within a row" ; + :Sigma0_Usable_Flag_3.long_name = "Eight bit flags indicating whether or not the third set of eight sigma-0 measurements is usable for wind retrieval" ; + :Sigma0_Usable_Flag_3.valid_range = 0, 0 ; + :Sigma0_Usable_Flag_3_dim_0.name = "row" ; + :Sigma0_Usable_Flag_3_dim_0.long_name = "WVC row index" ; + :Sigma0_Usable_Flag_3_dim_1.name = "WVC" ; + :Sigma0_Usable_Flag_3_dim_1.long_name = "WVC index within a row" ; + :Surface_Flag.long_name = "Bit flags indicating land and ice contamination of data" ; + :Surface_Flag.valid_range = 0, 0 ; + :Surface_Flag_dim_0.name = "row" ; + :Surface_Flag_dim_0.long_name = "WVC row index" ; + :Surface_Flag_dim_1.name = "WVC" ; + :Surface_Flag_dim_1.long_name = "WVC index within a row" ; + :Surface_Flag_dim_2.name = "Sigma0-Dimension" ; + :Surface_Flag_dim_2.long_name = "Sigma0 position index" ; data: NSCAT%20Rev%2017.WVC_Lat = diff --git a/ncdap_test/expected3/D1.dmp b/ncdap_test/expected3/D1.dmp index 3568ff9800..07c1e2a9fd 100644 --- a/ncdap_test/expected3/D1.dmp +++ b/ncdap_test/expected3/D1.dmp @@ -7,6 +7,9 @@ variables: char Drifters.location(Drifters, maxStrlen64) ; double Drifters.latitude(Drifters) ; double Drifters.longitude(Drifters) ; + +// global attributes: + :_location.Description = "String describing general location (southern ocean,oregon coast, etc.) of drifter deployment." ; data: Drifters.instrument_id = diff --git a/ncdap_test/expected3/Drifters.dmp b/ncdap_test/expected3/Drifters.dmp index c38354b683..5f89b318f5 100644 --- a/ncdap_test/expected3/Drifters.dmp +++ b/ncdap_test/expected3/Drifters.dmp @@ -63,6 +63,12 @@ variables: Drifters.Calibration_File:Description = "Path to the file on our file server of the calibration file for the drifter." ; char Drifters.Drifter_Type(Drifters, maxStrlen64) ; Drifters.Drifter_Type:Description = "Type of drifter." ; + +// global attributes: + :Facility.PrincipleInvestigator = "Mark Abbott\n", + "Ph.D" ; + :Facility.DataCenter = "COAS Environmental Computer Facility" ; + :Facility.DrifterType = "MetOcean WOCE/OCM" ; data: Drifters.Drifter_ID = diff --git a/ncdap_test/expected3/EOSDB.dmp b/ncdap_test/expected3/EOSDB.dmp index a804d9b0d5..5413b4f1f4 100644 --- a/ncdap_test/expected3/EOSDB.dmp +++ b/ncdap_test/expected3/EOSDB.dmp @@ -104,6 +104,23 @@ variables: // global attributes: :history = "FERRET V4.11 (debug/no GUI) 19-Nov-95FERRET V4.20 (debug/no GUI) 12-Mar-96" ; :title = "COADS Surface Marine Observations (1854-1993)" ; + :Facility.PrincipleInvestigator = "Mark Abbott" ; + :Facility.DataCenter = "COAS Environmental Computer Facility" ; + :LON.units = "degrees_east" ; + :LON.modulo = " " ; + :LON.point_spacing = "even" ; + :LAT.units = "degrees_north" ; + :LAT.point_spacing = "even" ; + :TIME.units = "days since 1700-01-01 00:00:00" ; + :TIME.time_origin = "1-JAN-1700" ; + :TIME.point_spacing = "uneven" ; + :TIME.edges = "TIMEedges" ; + :TIMEedges.edges = " " ; + :SST.missing_value = -9.9999998e+33 ; + :SST._FillValue = -9.9999998e+33 ; + :SST.long_name = "Sea Surface Temperature" ; + :SST.history = "From all_coads_grid" ; + :SST.units = "deg C" ; data: Abbott_Image_Data.Image_Name = diff --git a/ncdap_test/expected3/OverideExample.dmp b/ncdap_test/expected3/OverideExample.dmp index 1dc27f3689..dec4ed68a2 100644 --- a/ncdap_test/expected3/OverideExample.dmp +++ b/ncdap_test/expected3/OverideExample.dmp @@ -11,6 +11,15 @@ variables: int exp.i(exp.i_0) ; int exp.data.i ; double exp.data.f(exp.data.f_0) ; + +// global attributes: + :GeneralInfo.Author = "Nathan\n", + "Potter" ; + :GeneralInfo.Facility = "Oregon State University\n", + "College of Oceanic and Atmospheric Sciences" ; + :GeneralInfo.Example = "This dataset is a simple example of how to use a .ovr file\n", + "in the INFO directory to override the default .info service output\n", + "of the OPeNDAP servlet." ; data: exp.ThreeD = diff --git a/ncdap_test/expected3/SimpleDrdsExample.dmp b/ncdap_test/expected3/SimpleDrdsExample.dmp index 861aecb06f..23b3f8ab24 100644 --- a/ncdap_test/expected3/SimpleDrdsExample.dmp +++ b/ncdap_test/expected3/SimpleDrdsExample.dmp @@ -157,6 +157,12 @@ variables: double Drifters.rellon3hr(Drifters) ; Drifters.rellon3hr:Description = "Relative Longitude: Change in longitude in the last 3 hours as determined by the GPS subsystem (Rlon3)" ; Drifters.rellon3hr:units = "degrees_east" ; + +// global attributes: + :Facility.PrincipleInvestigator = "Mark Abbott\n", + "Ph.D" ; + :Facility.DataCenter = "COAS Environmental Computer Facility" ; + :Facility.DrifterType = "MetOcean WOCE/OCM" ; data: Drifters.battery = 1000, 886.994922779284, 573.519986072456, diff --git a/ncdap_test/expected3/b31.dmp b/ncdap_test/expected3/b31.dmp index 67d94f278d..b5d4c962c8 100644 --- a/ncdap_test/expected3/b31.dmp +++ b/ncdap_test/expected3/b31.dmp @@ -11,6 +11,10 @@ variables: b31.class:long_name = "class is dismissed" ; char b31.text(b31, maxStrlen64) ; b31.text:long_name = "textually yours" ; + +// global attributes: + :b31.foo.long_name = "It is beyond all recognition" ; + :b31.foo.short_name = "foobar" ; data: b32 = 1 ; diff --git a/ncdap_test/expected3/bears.nc.dmp b/ncdap_test/expected3/bears.nc.dmp index a1679341cd..5ad2b9f50a 100644 --- a/ncdap_test/expected3/bears.nc.dmp +++ b/ncdap_test/expected3/bears.nc.dmp @@ -7,8 +7,7 @@ dimensions: variables: short l(l) ; char bears(i, j, maxStrlen64) ; - bears:act = "text string\n", - "\t123" ; + bears:act = "text string\\012\\011123" ; bears:acs = -40s ; bears:acl = 17000 ; bears:acf = -2.f, 1.f, 0.f ; @@ -20,10 +19,10 @@ variables: double cross(i, j) ; // global attributes: - :history = "This is an example of a multi-line global\n", - "attribute. It could be used for representing the\n", - "processing history of the data, for example." ; + :history = "This is an example of a multi-line global\\012attribute. It could be used for representing the\\012processing history of the data, for example." ; :DODS_EXTRA.Unlimited_Dimension = "k" ; + :i.i_1.attr3_1 = "17" ; + :i.i_1.attr3_2 = 19., 23., 27. ; data: l = 10, 9, 8 ; diff --git a/ncdap_test/expected3/ber-2002-10-01.nc.dmp b/ncdap_test/expected3/ber-2002-10-01.nc.dmp index da164462ed..9f56820402 100644 --- a/ncdap_test/expected3/ber-2002-10-01.nc.dmp +++ b/ncdap_test/expected3/ber-2002-10-01.nc.dmp @@ -21,6 +21,379 @@ variables: // global attributes: :Conventions = "CF-1.0" ; :Institution = "CSISS,GMU" ; + :Lineage.History = "\n", + "\n", + "\n", + " \n", + " \n", + " \n", + "\t\t \n", + " This lineage information documents the source and processing performed by the WCS server in the CEOP satellite data server.\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "\t \n", + "\t\t\t\t SatelliteSwathToLatitudeLongitude\n", + "\t\t\t\t ForwardMapping\n", + "\t\t\t\t\n", + " \n", + " \n", + " \n", + " \n", + "\t\t\t Perform georectification by transforming satellite swath coordinate system to Latitude-Longitude coordinate system. \n", + " \n", + " \n", + " \n", + " 2008-05-21T20:12:12.00000Z\n", + " \n", + " \n", + " \n", + " \n", + " Wenli Yang\n", + " \n", + " \n", + " NASA GES DISC\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " 301-614-5312\n", + " \n", + " \n", + " \n", + " \n", + " Wenli.Yang@nasa.gov\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "\t\t\t\t\n", + "\t\t\t\t Interpolation\n", + "\t\t\t\t NearestNeighbor Interpolation \n", + "\t\t\t\t\n", + " \n", + " \n", + " \n", + " Interpolatiion is needed for output cells containing no valid input values.\n", + " \n", + " \n", + " 2008-05-21T20:12:12.000000Z\n", + " \n", + " \n", + " \n", + " \n", + " Wenli Yang\n", + " \n", + " \n", + " NASA GES DISC\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " 301-614-5312\n", + " \n", + " \n", + " \n", + " \n", + " Wenli.Yang@nasa.gov\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "\t\t\t\t\n", + "\t\t\t\t QualityScreen\n", + "\t\t\t\t AIRSPerPixelQAFiltering\n", + "\t\t\t\t\n", + " \n", + " \n", + " \n", + " Input cells not meeting QA criteria must be excluded in the resultant coverage.\n", + " \n", + " \n", + " 2008-05-21T20:12:12.000000Z\n", + " \n", + " \n", + " \n", + " \n", + " Wenli Yang\n", + " \n", + " \n", + " NASA GES DISC\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " 301-614-5312\n", + " \n", + " \n", + " \n", + " \n", + " Wenli.Yang@nasa.gov\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "\n", + "\n", + " \n", + " \n", + " \n", + " Input AIRS Release 5 Level 2 granule\n", + " \n", + " \n", + " \n", + " \n", + " \n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\tOGC:Swath\n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\tOGC\n", + "\t\t\t\t\t\n", + "\t\t\t\t\n", + "\t\t\t \n", + "\t\t \n", + " \n", + " \n", + " \n", + " \n", + " <CharacterString>Input AIRS Release 5 Level 2 granule</CharacterString>\n", + " \n", + " \n", + " \n", + " \n", + " 2004-10-01\n", + " \n", + " \n", + " publication\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " NASA GES DISC\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " ftp://airspar1u.ecs.nasa.gov/data/s4pa/Aqua_AIRS_Level2/AIRX2RET.005/2002/274/AIRS.2002.10.01.097.L2.RetStd.v5.0.14.0.G07227014224.hdf\n", + " \n", + " \n", + " ftp\n", + " \n", + " \n", + " download\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " originator\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "\t\t\t\t\n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\t59.542054 -91.525519\n", + "\t\t\t\t\t\t\t\t\t\t64.006578 -122.761953\n", + "\t\t\t\t\t\t\t\t\t\t42.866636 -126.317500\n", + "\t\t\t\t\t\t\t\t\t\t40.097498 -106.352680\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\n", + "\t\t\t\t\t\n", + "\t\t\t\t\n", + " \n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\t2002-10-01T09:18:00.000000Z\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\t2002-10-01T09:23:59.999999Z\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\n", + "\t\t\t\t\t\n", + "\t\t\t\t\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " Input AIRS Release 5 Level 2 granule\n", + " \n", + " \n", + " \n", + " \n", + " \n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\tOGC:Swath\n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\tOGC\n", + "\t\t\t\t\t\n", + "\t\t\t\t\n", + "\t\t\t \n", + "\t\t \n", + " \n", + " \n", + " \n", + " \n", + " <CharacterString>Input AIRS Release 5 Level 2 granule</CharacterString>\n", + " \n", + " \n", + " \n", + " \n", + " 2004-10-01\n", + " \n", + " \n", + " publication\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " NASA GES DISC\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " ftp://airspar1u.ecs.nasa.gov/data/s4pa/Aqua_AIRS_Level2/AIRX2RET.005/2002/274/AIRS.2002.10.01.193.L2.RetStd.v5.0.14.0.G07227072611.hdf\n", + " \n", + " \n", + " ftp\n", + " \n", + " \n", + " download\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " originator\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + "\t\t\t\t\n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\t50.182469 -108.424849\n", + "\t\t\t\t\t\t\t\t\t\t53.793611 -84.244362\n", + "\t\t\t\t\t\t\t\t\t\t74.889234 -88.293173\n", + "\t\t\t\t\t\t\t\t\t\t68.007927 -132.994761\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\n", + "\t\t\t\t\t\n", + "\t\t\t\t\n", + " \n", + "\t\t\t\t\t\n", + "\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\t2002-10-01T19:46:00.000000Z\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\t\t2002-10-01T19:51:59.999999Z\n", + "\t\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\t\n", + "\t\t\t\t\t\t\n", + "\t\t\t\t\t\n", + "\t\t\t\t\n", + " \n", + " \n", + " \n", + " \n", + " \n", + " \n", + " " ; data: TSurfAir = diff --git a/ncdap_test/expected3/in.nc.dmp b/ncdap_test/expected3/in.nc.dmp index 4cc005853b..0e5ddb6800 100644 --- a/ncdap_test/expected3/in.nc.dmp +++ b/ncdap_test/expected3/in.nc.dmp @@ -118,18 +118,14 @@ variables: float one_dmn_var(bnd) ; float att_var ; att_var:byte_att = 0b ; - att_var:char_att = "Sentence one.\n", - "Sentence two.\n", - "" ; + att_var:char_att = "Sentence one.\\012Sentence two.\\012" ; att_var:short_att = 37s ; att_var:int_att = 73 ; att_var:float_att = 73.f, 72.f, 71.f ; att_var:double_att = 73. ; int bnd_var(lev, bnd) ; bnd_var:byte_att = 0b ; - bnd_var:char_att = "Sentence one.\n", - "Sentence two.\n", - "" ; + bnd_var:char_att = "Sentence one.\\012Sentence two.\\012" ; bnd_var:short_att = 37s ; bnd_var:int_att = 73 ; bnd_var:float_att = 73.f ; @@ -325,8 +321,7 @@ variables: // global attributes: :Conventions = "NCAR-CSM" ; - :history = "History global attribute.\n", - "" ; + :history = "History global attribute.\\012" ; :julian_day = 200000.04 ; :DODS_EXTRA.Unlimited_Dimension = "time" ; data: diff --git a/ncdap_test/expected3/in1.nc.dmp b/ncdap_test/expected3/in1.nc.dmp index d31d7d35c2..85e2b7402e 100644 --- a/ncdap_test/expected3/in1.nc.dmp +++ b/ncdap_test/expected3/in1.nc.dmp @@ -125,18 +125,14 @@ variables: float one_dmn_var(bnd) ; float att_var ; att_var:byte_att = 0b ; - att_var:char_att = "Sentence one.\n", - "Sentence two.\n", - "" ; + att_var:char_att = "Sentence one.\\012Sentence two.\\012" ; att_var:short_att = 37s ; att_var:int_att = 73 ; att_var:float_att = 73.f, 72.f, 71.f ; att_var:double_att = 73. ; int bnd_var(lev, bnd) ; bnd_var:byte_att = 0b ; - bnd_var:char_att = "Sentence one.\n", - "Sentence two.\n", - "" ; + bnd_var:char_att = "Sentence one.\\012Sentence two.\\012" ; bnd_var:short_att = 37s ; bnd_var:int_att = 73 ; bnd_var:float_att = 73.f ; @@ -345,8 +341,7 @@ variables: // global attributes: :Conventions = "NCAR-CSM" ; - :history = "History global attribute.\n", - "" ; + :history = "History global attribute.\\012" ; :julian_day = 200000.04 ; :DODS_EXTRA.Unlimited_Dimension = "time" ; data: diff --git a/ncdap_test/expected3/in_2.nc.dmp b/ncdap_test/expected3/in_2.nc.dmp index 17c50837ea..6063823e96 100644 --- a/ncdap_test/expected3/in_2.nc.dmp +++ b/ncdap_test/expected3/in_2.nc.dmp @@ -119,18 +119,14 @@ variables: float one_dmn_var(bnd) ; float att_var ; att_var:byte_att = 0b ; - att_var:char_att = "Sentence one.\n", - "Sentence two.\n", - "" ; + att_var:char_att = "Sentence one.\\012Sentence two.\\012" ; att_var:short_att = 37s ; att_var:int_att = 73 ; att_var:float_att = 73.f, 72.f, 71.f ; att_var:double_att = 73. ; int bnd_var(lev, bnd) ; bnd_var:byte_att = 0b ; - bnd_var:char_att = "Sentence one.\n", - "Sentence two.\n", - "" ; + bnd_var:char_att = "Sentence one.\\012Sentence two.\\012" ; bnd_var:short_att = 37s ; bnd_var:int_att = 73 ; bnd_var:float_att = 73.f ; @@ -327,8 +323,7 @@ variables: // global attributes: :Conventions = "NCAR-CSM" ; - :history = "History global attribute.\n", - "" ; + :history = "History global attribute.\\012" ; :julian_day = 200000.04 ; :DODS_EXTRA.Unlimited_Dimension = "time" ; data: diff --git a/ncdap_test/expected3/in_no_three_double_dmn.nc.dmp b/ncdap_test/expected3/in_no_three_double_dmn.nc.dmp index ca15ca58f2..4984abcf79 100644 --- a/ncdap_test/expected3/in_no_three_double_dmn.nc.dmp +++ b/ncdap_test/expected3/in_no_three_double_dmn.nc.dmp @@ -118,18 +118,14 @@ variables: float one_dmn_var(bnd) ; float att_var ; att_var:byte_att = 0b ; - att_var:char_att = "Sentence one.\n", - "Sentence two.\n", - "" ; + att_var:char_att = "Sentence one.\\012Sentence two.\\012" ; att_var:short_att = 37s ; att_var:int_att = 73 ; att_var:float_att = 73.f, 72.f, 71.f ; att_var:double_att = 73. ; int bnd_var(lev, bnd) ; bnd_var:byte_att = 0b ; - bnd_var:char_att = "Sentence one.\n", - "Sentence two.\n", - "" ; + bnd_var:char_att = "Sentence one.\\012Sentence two.\\012" ; bnd_var:short_att = 37s ; bnd_var:int_att = 73 ; bnd_var:float_att = 73.f ; @@ -325,8 +321,7 @@ variables: // global attributes: :Conventions = "NCAR-CSM" ; - :history = "History global attribute.\n", - "" ; + :history = "History global attribute.\\012" ; :julian_day = 200000.04 ; :DODS_EXTRA.Unlimited_Dimension = "time" ; data: diff --git a/ncdap_test/expected3/in_v.nc.dmp b/ncdap_test/expected3/in_v.nc.dmp index 94a2e639e9..ee4d04c521 100644 --- a/ncdap_test/expected3/in_v.nc.dmp +++ b/ncdap_test/expected3/in_v.nc.dmp @@ -8,8 +8,7 @@ variables: // global attributes: :Conventions = "NCAR-CSM" ; - :history = "History global attribute.\n", - "" ; + :history = "History global attribute.\\012" ; :julian_day = 200000.04 ; :DODS_EXTRA.Unlimited_Dimension = "time" ; data: diff --git a/ncdap_test/expected3/nestedDAS.dmp b/ncdap_test/expected3/nestedDAS.dmp index 36995a46a8..972365dfae 100644 --- a/ncdap_test/expected3/nestedDAS.dmp +++ b/ncdap_test/expected3/nestedDAS.dmp @@ -6,6 +6,20 @@ variables: char b32(maxStrlen64) ; b32:billy = "Bob is my real name" ; b32:Robert = "Really wants to be called Billy" ; + +// global attributes: + :humans.position = "There are too many humans." ; + :humans.offer = "Here are a few..." ; + :b31.class.text.long_name = "textually yours" ; + :b31.class.text.short_name = "ty" ; + :b31.class.long_name = "class is dismissed" ; + :b31.class.short_name = "cid\n", + "kid\n", + "bid\n", + "did" ; + :b31.foo.long_name = "It is beyond all recognition" ; + :b31.foo.short_name = "foobar" ; + :b31.foo.SS_number = "304-66-9876" ; data: b31 = 0 ; diff --git a/ncdap_test/expected3/pbug0001b.dmp b/ncdap_test/expected3/pbug0001b.dmp index c187bbb627..d2a47af216 100644 --- a/ncdap_test/expected3/pbug0001b.dmp +++ b/ncdap_test/expected3/pbug0001b.dmp @@ -8,8 +8,8 @@ variables: float \3H(ISTA, IZ) ; // global attributes: - :bs5 = "foo\foo\\" ; - :dsp_ing_tiros_ourid = "NO11****C5>B\\" ; + :bs5 = "foo\\foo\\" ; + :dsp_ing_tiros_ourid = "NO11****C\\224\\2705>B\\217\\" ; :bung = 0.f, 1.f, 2.3f, -2.23456f ; data: diff --git a/ncdap_test/expected3/synth1.dmp b/ncdap_test/expected3/synth1.dmp index fd0dedbb30..f1128b7ede 100644 --- a/ncdap_test/expected3/synth1.dmp +++ b/ncdap_test/expected3/synth1.dmp @@ -3,7 +3,7 @@ dimensions: S1.v1_0 = 3 ; variables: int S1.v1(S1.v1_0) ; - S1.v1:a%201 = 32 ; + S1.v1:a%201 = 32 ; data: S1.v1 = 132, 232, 332 ; diff --git a/ncdap_test/expected3/synth4.dmp b/ncdap_test/expected3/synth4.dmp index 382416c61c..1d40a7dfd0 100644 --- a/ncdap_test/expected3/synth4.dmp +++ b/ncdap_test/expected3/synth4.dmp @@ -21,6 +21,7 @@ variables: // global attributes: :g1 = 3, 8, 16, 32 ; :s1 = "gvalue1" ; + :S2.lost1 = "value1" ; data: S1.v1 = diff --git a/ncdap_test/expected3/synth5.dmp b/ncdap_test/expected3/synth5.dmp index 98ec3e46a7..b544a4d44e 100644 --- a/ncdap_test/expected3/synth5.dmp +++ b/ncdap_test/expected3/synth5.dmp @@ -4,6 +4,9 @@ dimensions: long = 2 ; variables: float G1(lat, long) ; + +// global attributes: + :S1.v2.a1 = 32 ; data: G1 = diff --git a/ncdap_test/expected3/synth6.dmp b/ncdap_test/expected3/synth6.dmp index 3f263599d0..622e09ba27 100644 --- a/ncdap_test/expected3/synth6.dmp +++ b/ncdap_test/expected3/synth6.dmp @@ -12,9 +12,19 @@ dimensions: variables: byte S1.v1(S1.v1_0, S1.v1_1) ; int S1.v3(S1.v3_0, S1.v3_1) ; + S1.v3:a1 = 32 ; double S1.v5(S1.v5_0, S1.v5_1) ; short Q1.v2(Q1, Q1.v2_1) ; float Q1.v4(Q1, Q1.v4_1) ; + +// global attributes: + :globalattr = 177 ; + :CoreMetadata.OrbitNumber.Value = 375 ; + :CoreMetadata.OrbitNumber.Data_Location = "PGE" ; + :CoreMetadata.OrbitNumber.Mandatory = "FALSE" ; + :CoreMetadata.RangeBeginningDate.Value = "1997/12/21" ; + :CoreMetadata.RangeBeginningDate.Data_Location = "PGE" ; + :CoreMetadata.RangeBeginningDate.Mandatory = "FALSE" ; data: S1.v1 = diff --git a/ncdap_test/expected3/test.01.dmp b/ncdap_test/expected3/test.01.dmp index a8744060c0..e23844940c 100644 --- a/ncdap_test/expected3/test.01.dmp +++ b/ncdap_test/expected3/test.01.dmp @@ -15,6 +15,12 @@ variables: double f64 ; char s(maxStrlen64) ; char u(maxStrlen64) ; + +// global attributes: + :Facility.PrincipleInvestigator = "Mark Abbott\n", + "Ph.D" ; + :Facility.DataCenter = "COAS Environmental Computer Facility" ; + :Facility.DrifterType = "MetOcean WOCE/OCM" ; data: b = 0 ; diff --git a/ncdap_test/expected3/test.21.dmp b/ncdap_test/expected3/test.21.dmp index c0374329d9..3c374805c9 100644 --- a/ncdap_test/expected3/test.21.dmp +++ b/ncdap_test/expected3/test.21.dmp @@ -10,12 +10,6 @@ variables: int exp.i ; short exp.g(exp.g_0, exp.g_1, exp.g_2) ; short exp.f(exp.f_0, exp.f_1) ; - -// global attributes: - :Facility.PrincipleInvestigator = "Mark Abbott\n", - "Ph.D" ; - :Facility.DataCenter = "COAS Environmental Computer Facility" ; - :Facility.DrifterType = "MetOcean WOCE/OCM" ; data: exp.j = 1 ; diff --git a/ncdap_test/expected3/test.nc.dmp b/ncdap_test/expected3/test.nc.dmp index 464750abeb..775bd03ddd 100644 --- a/ncdap_test/expected3/test.nc.dmp +++ b/ncdap_test/expected3/test.nc.dmp @@ -19,7 +19,7 @@ variables: i:d = -1.79769313486232e+308, 1.79769313486232e+308, -1., 1., 660. ; float f ; double d ; - d:c = "\177AZ$&" ; + d:c = "\\200\\177AZ$&" ; char cr(Dr, maxStrlen64) ; byte br(Dr) ; short sr(Dr) ; @@ -152,7 +152,7 @@ variables: int i444(D4, D4, D4) ; // global attributes: - :Gc = "" ; + :Gc = "\\200" ; :Gb = -128b, 127b ; :Gs = -32768s, 32767s, 32767s ; :Gi = -2147483648, 2147483647, -2147483648, 2147483647 ; diff --git a/ncdap_test/expected3/text.nc.dmp b/ncdap_test/expected3/text.nc.dmp index cdc0ed2f2f..614aa67613 100644 --- a/ncdap_test/expected3/text.nc.dmp +++ b/ncdap_test/expected3/text.nc.dmp @@ -19,7 +19,7 @@ variables: i:d = -1.79769313486232e+308, 1.79769313486232e+308, -1., 1., 660. ; float f ; double d ; - d:c = "\177AZ$&" ; + d:c = "\\200\\177AZ$&" ; char cr(Dr, maxStrlen64) ; byte br(Dr) ; short sr(Dr) ; @@ -152,7 +152,7 @@ variables: int i444(D4, D4, D4) ; // global attributes: - :Gc = "" ; + :Gc = "\\200" ; :Gb = -128b, 127b ; :Gs = -32768s, 32767s, 32767s ; :Gi = -2147483648, 2147483647, -2147483648, 2147483647 ; diff --git a/ncdap_test/testdata3/Makefile.am b/ncdap_test/testdata3/Makefile.am index e3578bb6dc..2defd0d6de 100644 --- a/ncdap_test/testdata3/Makefile.am +++ b/ncdap_test/testdata3/Makefile.am @@ -93,6 +93,7 @@ test.vs4.das test.vs4.dds test.vs4.dods \ test.vs5.das test.vs5.dds test.vs5.dods \ text.nc.das text.nc.dds text.nc.dods \ whoi.das whoi.dds whoi.dods \ +kwcase.nc.das kwcase.nc.dds kwcase.nc.dods \ CMakeLists.txt # following are not legally convertible to dap2 diff --git a/ncdap_test/tst_ncdap.sh b/ncdap_test/tst_ncdap.sh index cc58538ca2..ca1c61dd9a 100755 --- a/ncdap_test/tst_ncdap.sh +++ b/ncdap_test/tst_ncdap.sh @@ -1,5 +1,7 @@ #!/bin/sh +if test "x$SETX" != x ; then set -x ; fi + quiet=0 leakcheck=0 @@ -17,26 +19,14 @@ mode="$3" # Locate the testdata and expected directory testdata3="${srcdir}/testdata3" expected3="${srcdir}/expected3" -expected4="${srcdir}/expected4" + +TITLE="DAP to netCDF-3 translation" +EXPECTED="$expected3" +PARAMS="${PARAMS}[cache]" # get the list of test files . ${srcdir}/tst_ncdap_shared.sh -FLAGS= - -case "$mode" in -*3) - EXPECTED="$expected3" - TITLE="DAP to netCDF-3 translation" - PARAMS="${PARAMS}[cache]" - ;; -*4) - EXPECTED="$expected4" - TITLE="DAP to netCDF-4 translation" - PARAMS="${PARAMS}[netcdf4][cache]" - ;; -esac - case "$mode" in file*) TESTURL="$FILEURL" @@ -55,8 +45,7 @@ remote*) esac RESULTSDIR="./results" -# Locate some tools -NCDUMP="${builddir}/ncdump/ncdump $FLAGS" +# if test "x$leakcheck" = "x1" ; then VALGRIND="valgrind -q --error-exitcode=2 --leak-check=full" fi @@ -84,7 +73,8 @@ for x in ${TESTSET} ; do if test "x${t}" = "x${x}" ; then isxfail=1; fi done ok=1 - if ${VALGRIND} ${NCDUMP} "${url}" > ${x}.dmp ; then ok=$ok; else ok=0; fi + echo command: ${VALGRIND} ${NCDUMP} ${FLAGS} "${url}" + if ${VALGRIND} ${NCDUMP} ${FLAGS} "${url}" > ${x}.dmp ; then ok=$ok; else ok=0; fi # compare with expected if diff -w ${EXPECTED}/${x}.dmp ${x}.dmp ; then ok=$ok; else ok=0; fi if test "$ok" = 1 ; then @@ -120,7 +110,6 @@ echo "pwd=" `pwd` totalcount=`expr $passcount + $failcount + $xfailcount` okcount=`expr $passcount + $xfailcount` - echo "*** PASSED: ${okcount}/${totalcount} ; ${xfailcount} expected failures ; ${failcount} unexpected failures" #failcount=0 diff --git a/ncdap_test/tst_ncdap3.sh b/ncdap_test/tst_ncdap3.sh index 0f82ff7567..4b82159b61 100755 --- a/ncdap_test/tst_ncdap3.sh +++ b/ncdap_test/tst_ncdap3.sh @@ -8,6 +8,6 @@ set -e #X="-x" #grind="checkleaks" -#exec sh $X ${srcdir}/tst_ncdap.sh "$srcdir" "$builddir" "file3" $grind -exec sh $X ${srcdir}/tst_ncdap.sh "$srcdir" "$builddir" "dds3" $grind +exec sh $X ${srcdir}/tst_ncdap.sh "$srcdir" "$builddir" "file" $grind +#exec sh $X ${srcdir}/tst_ncdap.sh "$srcdir" "$builddir" "dds" $grind diff --git a/ncdap_test/tst_ncdap_shared.sh b/ncdap_test/tst_ncdap_shared.sh index 8fbbe7e411..79acd1ad96 100755 --- a/ncdap_test/tst_ncdap_shared.sh +++ b/ncdap_test/tst_ncdap_shared.sh @@ -1,9 +1,9 @@ -# $Id: tst_ncdap_shared.sh,v 1.9 2009/12/03 03:42:39 dmh Exp $ - ################################################## # Local test info ################################################## +if test "x$SETX" != x ; then set -x ; fi + # Define the complete URLS FILEURL="file://${testdata3}" @@ -38,7 +38,8 @@ ber-2002-10-01.nc ceopL2AIRS2-2.nc \ data.nc fnoc1.nc \ in1.nc in_2.nc in.nc \ in_no_three_double_dmn.nc in_v.nc saco1.nc \ -test.nc text.nc" +test.nc text.nc \ +kwcase.nc" # XFAIL tests should be a subset of the other tests; this is used # only to detect which are considered XFAIL tests. @@ -46,7 +47,7 @@ XFAILTESTS="" # For now, remove some tests from windows platform. if [ `uname | cut -d "_" -f 1` = "MINGW32" ]; then - XFAILTESTS="$XFAILTESTS EOSDB OverideExample SimpleDrdsExample test.67 test.gr5 123bears.nc 123.nc bears.nc ber-2002-10-01 data.nc in1.nc in_2.nc in_no_three_double_dmn.nc test.nc text.nc test.22 test.23 test.gr1 in.nc ber-2002-10-01.nc" + XFAILTESTS="$XFAILTESTS EOSDB OverideExample SimpleDrdsExample test.67 test.gr5 123bears.nc 123.nc bears.nc ber-2002-10-01 data.nc in1.nc in_2.nc in_no_three_double_dmn.nc test.nc text.nc test.22 test.23 test.gr1 in.nc ber-2002-10-01.nc kwcase.nc" fi FILETESTS="${SYNTHETICDATA} ${ACTUALDATA1} ${ACTUALDATA2}" diff --git a/ncdap_test/tst_remote.sh b/ncdap_test/tst_remote.sh index f232f81387..23042ff5c9 100755 --- a/ncdap_test/tst_remote.sh +++ b/ncdap_test/tst_remote.sh @@ -1,8 +1,6 @@ #!/bin/sh -if test "x$srcdir" = x ; then srcdir=`pwd`; fi -. ../test_common.sh - +if test "x$SETX" != x ; then set -x ; fi set -e quiet=0 @@ -29,7 +27,7 @@ OCLOGFILE="" ; export OCLOGFILE # Capture arguments srcdir="$1" builddir="$2" -mode="$3" +#ignored mode="$3" if test "x$4" = "x" ; then cache=1 ; else cache=0; fi longtests="$5" @@ -183,22 +181,11 @@ testfile.nc \ text.nc \ " -case "$mode" in -3) - EXPECTED="$expected3" - TITLE="DAP to netCDF-3 translation" - PARAMS="${PARAMS}[netcdf3]" - XFAILTESTS="$XFAILTESTS3" - SVCFAILTESTS="$SVCFAILTESTS3" - ;; -4) - EXPECTED="$expected4" - TITLE="DAP to netCDF-4 translation" - PARAMS="${PARAMS}[netcdf4]" - XFAILTESTS="$XFAILTESTS4" - SVCFAILTESTS="$SVCFAILTESTS4" - ;; -esac +TITLE="DAP to netCDF-3 translation" +EXPECTED="$expected3" +PARAMS="${PARAMS}[netcdf3]" +XFAILTESTS="$XFAILTESTS3" +SVCFAILTESTS="$SVCFAILTESTS3" RESULTSDIR="./results" # Locate some tools diff --git a/oc2/Makefile.am b/oc2/Makefile.am index d85ee81e25..aa3d65f68e 100644 --- a/oc2/Makefile.am +++ b/oc2/Makefile.am @@ -46,5 +46,3 @@ bison:: dap.y rm -f dap.tab.c dap.tab.h bison --debug -d -p dap dap.y mv dap.tab.c dapy.c; mv dap.tab.h dapy.h - - diff --git a/oc2/dap.y b/oc2/dap.y index e20153904e..9154c61a89 100644 --- a/oc2/dap.y +++ b/oc2/dap.y @@ -52,7 +52,7 @@ int dapdebug = 0; start: dataset datasetbody - | dataset datasetbody SCAN_DATA + | dataset datasetbody SCAN_DATA /* The SCAN_DATA indicates serialized data follows */ | attr attributebody | err errorbody | error {dap_unrecognizedresponse(parsestate); YYABORT;} @@ -245,29 +245,29 @@ errorprog : /*empty*/ {$$=null;} | SCAN_PROG '=' WORD_WORD ';' {$$=$3;} */ name: WORD_WORD {$$=dapdecode(parsestate->lexstate,$1);} - | SCAN_ALIAS {$$=strdup("alias");} - | SCAN_ARRAY {$$=strdup("array");} - | SCAN_ATTR {$$=strdup("attributes");} - | SCAN_BYTE {$$=strdup("byte");} - | SCAN_DATASET {$$=strdup("dataset");} - | SCAN_DATA {$$=strdup("data");} - | SCAN_ERROR {$$=strdup("error");} - | SCAN_FLOAT32 {$$=strdup("float32");} - | SCAN_FLOAT64 {$$=strdup("float64");} - | SCAN_GRID {$$=strdup("grid");} - | SCAN_INT16 {$$=strdup("int16");} - | SCAN_INT32 {$$=strdup("int32");} - | SCAN_MAPS {$$=strdup("maps");} - | SCAN_SEQUENCE {$$=strdup("sequence");} - | SCAN_STRING {$$=strdup("string");} - | SCAN_STRUCTURE {$$=strdup("structure");} - | SCAN_UINT16 {$$=strdup("uint16");} - | SCAN_UINT32 {$$=strdup("uint32");} - | SCAN_URL {$$=strdup("url");} - | SCAN_CODE {$$=strdup("code");} - | SCAN_MESSAGE {$$=strdup("message");} - | SCAN_PROG {$$=strdup("program");} - | SCAN_PTYPE {$$=strdup("program_type");} + | SCAN_ALIAS {$$=strdup($1);} + | SCAN_ARRAY {$$=strdup($1);} + | SCAN_ATTR {$$=strdup($1);} + | SCAN_BYTE {$$=strdup($1);} + | SCAN_DATASET {$$=strdup($1);} + | SCAN_DATA {$$=strdup($1);} + | SCAN_ERROR {$$=strdup($1);} + | SCAN_FLOAT32 {$$=strdup($1);} + | SCAN_FLOAT64 {$$=strdup($1);} + | SCAN_GRID {$$=strdup($1);} + | SCAN_INT16 {$$=strdup($1);} + | SCAN_INT32 {$$=strdup($1);} + | SCAN_MAPS {$$=strdup($1);} + | SCAN_SEQUENCE {$$=strdup($1);} + | SCAN_STRING {$$=strdup($1);} + | SCAN_STRUCTURE {$$=strdup($1);} + | SCAN_UINT16 {$$=strdup($1);} + | SCAN_UINT32 {$$=strdup($1);} + | SCAN_URL {$$=strdup($1);} + | SCAN_CODE {$$=strdup($1);} + | SCAN_MESSAGE {$$=strdup($1);} + | SCAN_PROG {$$=strdup($1);} + | SCAN_PTYPE {$$=strdup($1);} ; %% diff --git a/oc2/dapy.c b/oc2/dapy.c index d1cfa63abf..c4031eb3a8 100644 --- a/oc2/dapy.c +++ b/oc2/dapy.c @@ -1875,139 +1875,139 @@ YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default); case 84: #line 248 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("alias");} + {(yyval)=strdup((yyvsp[0]));} #line 1880 "dap.tab.c" /* yacc.c:1646 */ break; case 85: #line 249 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("array");} + {(yyval)=strdup((yyvsp[0]));} #line 1886 "dap.tab.c" /* yacc.c:1646 */ break; case 86: #line 250 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("attributes");} + {(yyval)=strdup((yyvsp[0]));} #line 1892 "dap.tab.c" /* yacc.c:1646 */ break; case 87: #line 251 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("byte");} + {(yyval)=strdup((yyvsp[0]));} #line 1898 "dap.tab.c" /* yacc.c:1646 */ break; case 88: #line 252 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("dataset");} + {(yyval)=strdup((yyvsp[0]));} #line 1904 "dap.tab.c" /* yacc.c:1646 */ break; case 89: #line 253 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("data");} + {(yyval)=strdup((yyvsp[0]));} #line 1910 "dap.tab.c" /* yacc.c:1646 */ break; case 90: #line 254 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("error");} + {(yyval)=strdup((yyvsp[0]));} #line 1916 "dap.tab.c" /* yacc.c:1646 */ break; case 91: #line 255 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("float32");} + {(yyval)=strdup((yyvsp[0]));} #line 1922 "dap.tab.c" /* yacc.c:1646 */ break; case 92: #line 256 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("float64");} + {(yyval)=strdup((yyvsp[0]));} #line 1928 "dap.tab.c" /* yacc.c:1646 */ break; case 93: #line 257 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("grid");} + {(yyval)=strdup((yyvsp[0]));} #line 1934 "dap.tab.c" /* yacc.c:1646 */ break; case 94: #line 258 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("int16");} + {(yyval)=strdup((yyvsp[0]));} #line 1940 "dap.tab.c" /* yacc.c:1646 */ break; case 95: #line 259 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("int32");} + {(yyval)=strdup((yyvsp[0]));} #line 1946 "dap.tab.c" /* yacc.c:1646 */ break; case 96: #line 260 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("maps");} + {(yyval)=strdup((yyvsp[0]));} #line 1952 "dap.tab.c" /* yacc.c:1646 */ break; case 97: #line 261 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("sequence");} + {(yyval)=strdup((yyvsp[0]));} #line 1958 "dap.tab.c" /* yacc.c:1646 */ break; case 98: #line 262 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("string");} + {(yyval)=strdup((yyvsp[0]));} #line 1964 "dap.tab.c" /* yacc.c:1646 */ break; case 99: #line 263 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("structure");} + {(yyval)=strdup((yyvsp[0]));} #line 1970 "dap.tab.c" /* yacc.c:1646 */ break; case 100: #line 264 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("uint16");} + {(yyval)=strdup((yyvsp[0]));} #line 1976 "dap.tab.c" /* yacc.c:1646 */ break; case 101: #line 265 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("uint32");} + {(yyval)=strdup((yyvsp[0]));} #line 1982 "dap.tab.c" /* yacc.c:1646 */ break; case 102: #line 266 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("url");} + {(yyval)=strdup((yyvsp[0]));} #line 1988 "dap.tab.c" /* yacc.c:1646 */ break; case 103: #line 267 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("code");} + {(yyval)=strdup((yyvsp[0]));} #line 1994 "dap.tab.c" /* yacc.c:1646 */ break; case 104: #line 268 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("message");} + {(yyval)=strdup((yyvsp[0]));} #line 2000 "dap.tab.c" /* yacc.c:1646 */ break; case 105: #line 269 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("program");} + {(yyval)=strdup((yyvsp[0]));} #line 2006 "dap.tab.c" /* yacc.c:1646 */ break; case 106: #line 270 "dap.y" /* yacc.c:1646 */ - {(yyval)=strdup("program_type");} + {(yyval)=strdup((yyvsp[0]));} #line 2012 "dap.tab.c" /* yacc.c:1646 */ break; diff --git a/test_common.in b/test_common.in index 89720b5214..d559dd3d79 100644 --- a/test_common.in +++ b/test_common.in @@ -115,12 +115,12 @@ else ext="" fi -# We need to locate certain executables (and other things) -# and capture absolute paths -NCDUMP="${top_builddir}/ncdump${VS}/ncdump${ext}" -NCCOPY="${top_builddir}/ncdump${VS}/nccopy${ext}" -NCGEN="${top_builddir}/ncgen${VS}/ncgen${ext}" -NCGEN3="${top_builddir}/ncgen3${VS}/ncgen3${ext}" +# We need to locate certain executables (and other things), +# capture absolute paths, and make visible +export NCDUMP="${top_builddir}/ncdump${VS}/ncdump${ext}" +export NCCOPY="${top_builddir}/ncdump${VS}/nccopy${ext}" +export NCGEN="${top_builddir}/ncgen${VS}/ncgen${ext}" +export NCGEN3="${top_builddir}/ncgen3${VS}/ncgen3${ext}" # Temporary hacks (until we have a test_utils directory) # to locate certain specific test files