summaryrefslogtreecommitdiffstats
path: root/src/H5Odtype.c
diff options
context:
space:
mode:
authorRobb Matzke <matzke@llnl.gov>1998-08-10 18:15:14 (GMT)
committerRobb Matzke <matzke@llnl.gov>1998-08-10 18:15:14 (GMT)
commit9754e9373b731856dbf61fdb9c99501f452ca552 (patch)
tree0bb99d2caf87b9ec8e4dfd2a52bf03b5c7d06055 /src/H5Odtype.c
parent1d0b2915c2d492ecf35b83ff65287d5d95bf5f7c (diff)
downloadhdf5-9754e9373b731856dbf61fdb9c99501f452ca552.zip
hdf5-9754e9373b731856dbf61fdb9c99501f452ca552.tar.gz
hdf5-9754e9373b731856dbf61fdb9c99501f452ca552.tar.bz2
[svn-r584] Changes since 19980806
---------------------- ./doc/html/Datatypes.html ./doc/html/H5.format.html ./src/H5.c ./src/H5Odtype.c ./src/H5T.c ./src/H5Tconv.c ./src/H5Tpkg.h ./src/H5Tpublic.h ./test/dtypes.c Changed the values of the H5T_str_t type in order to make a distinction between C's null terminated strings and strings which are not null terminated. The string character set and padding method are saved to the hdf5 file instead of using defaults. Added conversion function from one fixed-length string type to another. ./test/chunk.c Fixed to work with new filter API
Diffstat (limited to 'src/H5Odtype.c')
-rw-r--r--src/H5Odtype.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/H5Odtype.c b/src/H5Odtype.c
index 8e44223..d4a4d6f 100644
--- a/src/H5Odtype.c
+++ b/src/H5Odtype.c
@@ -122,8 +122,9 @@ H5O_dtype_decode_helper(const uint8 **pp, H5T_t *dt)
dt->u.atomic.offset = 0;
dt->u.atomic.lsb_pad = H5T_PAD_ZERO;
dt->u.atomic.msb_pad = H5T_PAD_ZERO;
- dt->u.atomic.u.s.cset = H5T_CSET_ASCII;
- dt->u.atomic.u.s.pad = H5T_STR_NULL;
+
+ dt->u.atomic.u.s.pad = flags & 0x0f;
+ dt->u.atomic.u.s.cset = (flags>>4) & 0x0f;
break;
case H5T_FLOAT:
@@ -327,8 +328,9 @@ H5O_dtype_encode_helper(uint8 **pp, const H5T_t *dt)
assert (dt->u.atomic.offset == 0);
assert (dt->u.atomic.lsb_pad == H5T_PAD_ZERO);
assert (dt->u.atomic.msb_pad == H5T_PAD_ZERO);
- assert (dt->u.atomic.u.s.cset == H5T_CSET_ASCII);
- assert (dt->u.atomic.u.s.pad == H5T_STR_NULL);
+
+ flags |= (dt->u.atomic.u.s.pad & 0x0f);
+ flags |= (dt->u.atomic.u.s.cset & 0x0f) << 4;
break;
case H5T_FLOAT: