summaryrefslogtreecommitdiffstats
path: root/tools/h5repack/testh5repack_dset.c
diff options
context:
space:
mode:
authorRaymond Lu <songyulu@hdfgroup.org>2004-05-26 19:43:56 (GMT)
committerRaymond Lu <songyulu@hdfgroup.org>2004-05-26 19:43:56 (GMT)
commit6223a679ce610d98a7735c426c76162a3ecd34b1 (patch)
tree2520cb26ace7d6f6e4e9ab5698764162623d2a15 /tools/h5repack/testh5repack_dset.c
parentdd03ef3f27627a0f482bb847b23664879df736fc (diff)
downloadhdf5-6223a679ce610d98a7735c426c76162a3ecd34b1.zip
hdf5-6223a679ce610d98a7735c426c76162a3ecd34b1.tar.gz
hdf5-6223a679ce610d98a7735c426c76162a3ecd34b1.tar.bz2
[svn-r8582] *** empty log message ***
Diffstat (limited to 'tools/h5repack/testh5repack_dset.c')
-rw-r--r--tools/h5repack/testh5repack_dset.c26
1 files changed, 25 insertions, 1 deletions
diff --git a/tools/h5repack/testh5repack_dset.c b/tools/h5repack/testh5repack_dset.c
index 57a5b27..7f6345b 100644
--- a/tools/h5repack/testh5repack_dset.c
+++ b/tools/h5repack/testh5repack_dset.c
@@ -617,7 +617,31 @@ void write_dset_in(hid_t loc_id,
write_dset(loc_id,3,dims3,"float3D",H5T_NATIVE_FLOAT,buf83);
}
-
+/*-------------------------------------------------------------------------
+ * Function: write_null_dset
+ *
+ * Purpose: write null dataset in LOC_ID
+ *
+ * Programmer: Raymond Lu, slu@ncsa.uiuc.edu
+ *
+ * Date: May 24, 2004
+ *
+ *-------------------------------------------------------------------------
+ */
+void write_null_dset(hid_t loc_id)
+{
+ hid_t sid, dset_id;
+ int val = 2;
+
+ /* Create the null dataset */
+ sid = H5Screate(H5S_NULL);
+ dset_id = H5Dcreate(loc_id,"null_dset",H5T_NATIVE_INT,sid,H5P_DEFAULT);
+ H5Dwrite(dset_id,H5T_NATIVE_INT,H5S_ALL,H5S_ALL,H5P_DEFAULT,&val);
+
+ /* Close */
+ H5Dclose(dset_id);
+ H5Sclose(sid);
+}
/*-------------------------------------------------------------------------
* Function: make_dset_reg_ref