diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2009-11-16 20:45:05 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2009-11-16 20:45:05 (GMT) |
commit | d2b87ec47ebdb096c331c7b62a195b9cea2f33ae (patch) | |
tree | a066f01361afaf5df457cef612bb0bb9fd80fe18 /src/H5T.c | |
parent | ee5a1e07350f0dcf3ef07d9443aa2f4c073392f4 (diff) | |
download | hdf5-d2b87ec47ebdb096c331c7b62a195b9cea2f33ae.zip hdf5-d2b87ec47ebdb096c331c7b62a195b9cea2f33ae.tar.gz hdf5-d2b87ec47ebdb096c331c7b62a195b9cea2f33ae.tar.bz2 |
[svn-r17896] Description:
Bring r17546:17895 from trunk to revise_chunks branch. Changes to
fixed and extensible array dataset chunk indexing code to accommodate changes
to private APIs in those interfaces. Also, other adjustments to source code
and expected output in response to changes on the trunk.
Tested on:
FreeBSD/32 6.3 (duty) in debug mode
FreeBSD/64 6.3 (liberty) w/C++ & FORTRAN, in debug mode
Linux/32 2.6 (jam) w/PGI compilers, w/default API=1.8.x,
w/C++ & FORTRAN, w/threadsafe, in debug mode
Linux/64-amd64 2.6 (smirom) w/Intel compilers, w/default API=1.6.x,
w/C++ & FORTRAN, in production mode
Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN,
w/szip filter, in production mode
Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN,
in production mode
Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in debug mode
Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode
Mac OS X/32 10.6.2 (amazon) in debug mode
Mac OS X/32 10.6.2 (amazon) w/C++ & FORTRAN, w/threadsafe,
in production mode
Diffstat (limited to 'src/H5T.c')
-rw-r--r-- | src/H5T.c | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -2976,8 +2976,8 @@ H5T_create(H5T_class_t type, size_t size) dt->shared->type = type; if(type==H5T_COMPOUND) { - dt->shared->u.compnd.packed=TRUE; /* Start out packed */ - dt->shared->u.compnd.sorted=H5T_SORT_VALUE; /* Start out sorted by value */ + dt->shared->u.compnd.packed=FALSE; /* Start out unpacked */ + dt->shared->u.compnd.memb_size=0; } /* end if */ else if(type==H5T_OPAQUE) /* Initialize the tag in case it's not set later. A null tag will @@ -3678,7 +3678,13 @@ H5T_set_size(H5T_t *dt, size_t size) if(size<(max_offset+max_size)) HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "size shrinking will cut off last member "); + + /* Compound must not have been packed previously */ + /* We will check if resizing changed the packed state of + * this type at the end of this function */ + HDassert(!dt->shared->u.compnd.packed); } + break; case H5T_STRING: @@ -3754,6 +3760,10 @@ H5T_set_size(H5T_t *dt, size_t size) dt->shared->u.atomic.prec = prec; } } /* end if */ + + /* Check if the new compound type is packed */ + if(dt->shared->type == H5T_COMPOUND) + H5T_update_packed(dt); } done: |