diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 1998-02-04 14:56:06 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 1998-02-04 14:56:06 (GMT) |
commit | 3d5f479f878d0d2b85fb03f30971a58c2541ab54 (patch) | |
tree | a772ddd8f12f2a630905fcc197b55d9ae6ccd7c6 /src | |
parent | 71be4b3cca41fef6771eec2a49fee66b12f7277b (diff) | |
download | hdf5-3d5f479f878d0d2b85fb03f30971a58c2541ab54.zip hdf5-3d5f479f878d0d2b85fb03f30971a58c2541ab54.tar.gz hdf5-3d5f479f878d0d2b85fb03f30971a58c2541ab54.tar.bz2 |
[svn-r217] Fixed fence-post & memory copy errors in H5F_encode_length_unusual()
Diffstat (limited to 'src')
-rw-r--r-- | src/H5F.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -177,7 +177,7 @@ H5F_term_interface(void) void H5F_encode_length_unusual(const H5F_t *f, uint8 **p, uint8 *l) { - intn i = H5F_SIZEOF_SIZE(f); + intn i = (intn)H5F_SIZEOF_SIZE(f)-1; #ifdef WORDS_BIGENDIAN /* @@ -187,8 +187,8 @@ H5F_encode_length_unusual(const H5F_t *f, uint8 **p, uint8 *l) *(*p) = *(l + i); #else /* platform has little-endian integers */ - for (; i >= 0; i--, (*p)++) - *(*p) = *l; + HDmemcpy(*p,l,i+1); + *p+=(i+1); #endif #ifdef LATER |