summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPedro Vicente Nunes <pvn@hdfgroup.org>2007-04-02 20:28:14 (GMT)
committerPedro Vicente Nunes <pvn@hdfgroup.org>2007-04-02 20:28:14 (GMT)
commit104e1cd848e26eda1c774937c3beb38ff5861fd8 (patch)
tree6060c90d638783dd85f3b413e4e2ad15cba3e609 /src
parent26fdccf6cd0325756a9365c86fd373d3eb955095 (diff)
downloadhdf5-104e1cd848e26eda1c774937c3beb38ff5861fd8.zip
hdf5-104e1cd848e26eda1c774937c3beb38ff5861fd8.tar.gz
hdf5-104e1cd848e26eda1c774937c3beb38ff5861fd8.tar.bz2
[svn-r13573]
Bug fixes Reset external file list slots name_offset to a state when created (0) in H5P_dcrt_copy so that it conforms to an assertion in H5D_update_entry_info that assumes the name_offset is 0 at this point this fixes the problem of h5repack and external files, add a new test and files for an external file h5diff, check for an error return in H5D_get_storage_size tested linux 32, 64
Diffstat (limited to 'src')
-rw-r--r--src/H5Pdcpl.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/H5Pdcpl.c b/src/H5Pdcpl.c
index ee039c7..1e9f108 100644
--- a/src/H5Pdcpl.c
+++ b/src/H5Pdcpl.c
@@ -199,6 +199,9 @@ done:
* Programmer: Raymond Lu
* Tuesday, October 2, 2001
*
+ * Modifications: pvn, April 02, 2007
+ * Reset external file list slots name_offset to a state when created
+ *
*-------------------------------------------------------------------------
*/
/* ARGSUSED */
@@ -235,6 +238,21 @@ H5P_dcrt_copy(hid_t dst_plist_id, hid_t src_plist_id, void UNUSED *copy_data)
HDmemset(&dst_efl, 0, sizeof(H5O_efl_t));
if(NULL == H5O_msg_copy(H5O_EFL_ID, &src_efl, &dst_efl))
HGOTO_ERROR(H5E_PLIST, H5E_CANTINIT, FAIL, "can't copy external file list")
+
+ /* reset efl name_offset and heap_addr, these are the values when the dataset is created */
+ if (dst_efl.slot)
+ {
+ unsigned int i;
+
+ dst_efl.heap_addr = HADDR_UNDEF;
+ for ( i = 0; i < dst_efl.nused; i++)
+ {
+ dst_efl.slot[i].name_offset = 0;
+ }
+
+ }
+
+
if(NULL == H5O_msg_copy(H5O_PLINE_ID, &src_pline, &dst_pline))
HGOTO_ERROR(H5E_PLIST, H5E_CANTINIT, FAIL, "can't copy data pipeline")